Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

invalid argument value error

Status
Not open for further replies.

myatia

Programmer
Nov 21, 2002
232
I'm getting an "invalid argument value" error whenever I try to update a record, regardless of the values I try to enter. Here's a sample of my code that's getting the error:

Code:
ID = Request.Form("id")

set rs = server.createobject("ADODB.Recordset")
	
rs.cursorlocation = adUseServer
rs.cursortype = adOpenForwardOnly
rs.locktype = adLockOptimistic

st = "SELECT * FROM GuideData WHERE id = " & ID
rs.open st, connq, , , adCmdText

'' indexname is a character type, width 37
rs("indexname") = "your name here" 

rs.Update
rs.close()

I have no idea why I'm getting this error. It seems like a pretty basic update to me. Any help would be greatly appreciated.

Thanks,

Misty
 
Hi...
have you tried other cursortype ?
for example : adOpenStatic

----
TNX.
E.T.
 
Thanks for the suggestion, but they all result in the following:

Code:
Microsoft OLE DB Provider for ODBC Drivers (0x80004005)
[Microsoft][ODBC Visual FoxPro Driver]Invalid argument value
/career/career_guide/acguide_signup_demographics.asp, line 83

Line 83 is the line with rs.Update on it.
 
Hi...
OK, I think it's because of your DB and your connection string.
since I don't have any experience on FoxPRo, I can't tell you what to do, but have you tried other providers liek OLEDB ?

----
TNX.
E.T.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top