dbRecordConnection

This connection handle is supplied by the user directly in conjunction with the user supplied Recordset. Together with the parameters in dbEditParams, editing can be performed.

Property Syntax

Obj.dbRecordSetConnection = Connection Handle

Example

This example illustrates how to use user supplied RS and connection and execute editing. Note that connection string must also be supplied as it is assumed that editing table is within the same source.

<%
Set oRs=Server.CreateObject("ADODB.Recordset")
Set oConn=Server.CreateObject("ADODB.Connection")
SQL="Select * From Employees"
Connection="NWIND"
oConn.CommandTimeout = 30
oConn.Open Connection
oRs.open SQL,oConn,1,2,1
'Starts ASPDB Code
Set X= Server.CreateObject("ASP.DB")
dbQuickProps="1;;;Grid;4,auto;;;ACCESS;5,1,1"
X.dbRecordSet=oRs
X.dbRecordSetConnection=oConn
X.dbFormDisplayFlds=-1
X.dbNavigationItem="top,bottom,prev,next,edit,add,update,delete"
X.dbEditParams="TableName=Employees, EditLinkFlds=0+1, EditBookMarkFlds=0+1"
'X.dbstartup="editadd" 'works also
X.dbEditFlds="0,1,2,3,4,5"
X.dbEditUpdateROflds="0"
X.ASPDB
'Ends ASPDB Code
oRs.close
set oRs=nothing
%>