ADODB command object 
Author Message
 ADODB command object

I can't seem to set a command object variable in VBScript. The followinf
code works in Visual Basic but not in script.

Set cmd = AODObj.CreateObject("ADODB.Command")

How do I do this in script.



Mon, 02 Jun 2003 04:04:13 GMT  
 ADODB command object
What's AODObj supposed to be ???

Depending on the host for the script (the 1st works anywhere):

Set cmd = CreateObject("ADODB.Command")
Set cmd = Server.CreateObject("ADODB.Command")
Set cmd = WScript.CreateObject("ADODB.Command")

--
Michael Harris
Microsoft.MVP.Scripting
--

Please do not email questions - post them to the newsgroup instead.
--


Quote:
> I can't seem to set a command object variable in VBScript. The followinf
> code works in Visual Basic but not in script.

> Set cmd = AODObj.CreateObject("ADODB.Command")

> How do I do this in script.



Mon, 02 Jun 2003 09:47:17 GMT  
 ADODB command object
ADOObj is the connection object variable.

Thanks


Quote:
> What's AODObj supposed to be ???

> Depending on the host for the script (the 1st works anywhere):

> Set cmd = CreateObject("ADODB.Command")
> Set cmd = Server.CreateObject("ADODB.Command")
> Set cmd = WScript.CreateObject("ADODB.Command")

> --
> Michael Harris
> Microsoft.MVP.Scripting
> --

> Please do not email questions - post them to the newsgroup instead.
> --



> > I can't seem to set a command object variable in VBScript. The followinf
> > code works in Visual Basic but not in script.

> > Set cmd = AODObj.CreateObject("ADODB.Command")

> > How do I do this in script.



Mon, 02 Jun 2003 11:06:03 GMT  
 ADODB command object
Well it certainly doesn't have a CreateObject method ;-)...

--
Michael Harris
Microsoft.MVP.Scripting
--

Please do not email questions - post them to the newsgroup instead.
--


Quote:
> ADOObj is the connection object variable.

> Thanks



> > What's AODObj supposed to be ???

> > Depending on the host for the script (the 1st works anywhere):

> > Set cmd = CreateObject("ADODB.Command")
> > Set cmd = Server.CreateObject("ADODB.Command")
> > Set cmd = WScript.CreateObject("ADODB.Command")

> > --
> > Michael Harris
> > Microsoft.MVP.Scripting
> > --

> > Please do not email questions - post them to the newsgroup instead.
> > --



> > > I can't seem to set a command object variable in VBScript. The
followinf
> > > code works in Visual Basic but not in script.

> > > Set cmd = AODObj.CreateObject("ADODB.Command")

> > > How do I do this in script.



Mon, 02 Jun 2003 13:25:53 GMT  
 
 [ 4 post ] 

 Relevant Pages 

1. Sending command to a FoxPro database using ADODB.Command Object

2. Using adodb command object with transferspreadsheet

3. When to use ADODB.Command Object in ADO Programming

4. Using where IN with a ADODB.Command object...

5. When to use ADODB.Command Object in ADO Programming

6. ADODB.command Object and RecordCount

7. Err in using ADODB Command Object in VB.Net

8. Using browser-side ADODB.Command object?

9. Problem sending ADODB.Command object across MTS packages !!!

10. CursorType on an ADODB.Command object

11. Using browser-side ADODB.Command object?

12. Using browser-side ADODB.Command object?

 

 
Powered by phpBB® Forum Software