Hello Gang,
does anyone know a way to create a Client Side ADO recordset from a ADO Command object containing one or more Parameter objects, I can do it by creating the empty RecordSet object and setting the properties before the Open method is called, but I need to create a RecordSet with the Command object, here is what I've done so far
Form method: SetupConnection
with this
if .ConnectionEstablished
return .t.
endif
.oConnection = create('ADODB.Connection')
.oConnection.Open(.ConnectionString) && Set in the Init
.oCommand = create('adodb.Command')
.oCommand.ActiveConnection = .oConnection
.oCommand.CommandText = .cSQLString && Set in the Init
.oParameter_Batch_No = .oCommand.CreateParameter('batch_no',ADINTEGER,ADPARAMINPUT,2,.batch_no)
.oCommand.Parameters.Append(.oParameter_Batch_No)
.ConnectionEstablished = .t.
endwith
I then issue: .oRecordset = .oCommand.Execute(), which creates the RecordSet ok but it's server side. Apart from closing and reopening the RecordSet, I can't think of another way to set the location, any ideas gratefuly received
Regards
Pete Kane
Regards,
Peter J. Kane
Pete