Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Getting at foxpro with ADO.
Message
From
09/11/1998 11:56:35
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Internet applications
Title:
Getting at foxpro with ADO.
Miscellaneous
Thread ID:
00155769
Message ID:
00155769
Views:
51
Hey...

I've been working on an add form for a visual foxpro database I have. I want to use the addNew method from ADO. I'm having a lot of problems setting up the Recordset to point at a table, in order to do additions. I have no problem creaing a recordset to a SQL Query, and can read all of my data that way, but when I try to pass a table name to RS.open, I get command verb errors. Also, it complains about any value that I try to pass into the RS.lockType attribute.

Here is my initialization code that is leading to my progressive insanity:

Set OBJdbConnection = Server.CreateObject("ADODB.Connection")
OBJdbConnection.ConnectionTimeout = Session("ConnectionTimeout")
OBJdbConnection.CommandTimeout = Session("CommandTimeout")
OBJdbConnection.Open "DSN=AAASP"

Set RsAbstractList = Server.CreateObject("ADODB.Recordset")
RsAbstractList.ActiveConnection = OBJdbConnection
RsAbstractList.CursorType = adOpenKeySet
RsAbstractList.LockType = adLockOptimisticBatch
RsAbstractList.Source = "Aasp"
RsAbstractList.Open

As it stands, I get an error from the CursorType saying that "The application is using arguments that are of the wrong type, are out of acceptable range, or are in conflict with one another." If I comment that line out, I get an command verb error form the .open line.

Any advice would be fantastic, I'm at my wits' end.

Cheers,

Andy.
Next
Reply
Map
View

Click here to load this message in the networking platform