scottsanpedro
Programmer
Hi,
I have a simple call to an ADO subroutine that refreshes a recordset from SQL SERVER 2005 to my ACCESS 2007 DB.
Notice that there is a variable 'mCommandText' in the cmd.CommandText.
All I want to do is pass the name of the SP across to the class and it to run. But I'm getting errors.
Automating a general ADO call via a class.
Thanks if you can help
Scott
I have a simple call to an ADO subroutine that refreshes a recordset from SQL SERVER 2005 to my ACCESS 2007 DB.
Code:
Set cmd = New ADODB.Command
cmd.ActiveConnection = gcnn
cmd.CommandType = adCmdStoredProc
cmd.CommandText = mCommandText
Set rstServer = New ADODB.Recordset
rstServer.CursorLocation = adUseClient
rstServer.CursorType = adOpenKeyset
rstServer.Open cmd
Set Form_subfrmRenewalErrors.Recordset = rstServer
Form_subfrmRenewalErrors.Requery
Set cmd = Nothing
Set rstServer = Nothing
All I want to do is pass the name of the SP across to the class and it to run. But I'm getting errors.
Automating a general ADO call via a class.
Thanks if you can help
Scott