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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Problems with RS.Edit and adOpenDynamic

Status
Not open for further replies.

bgreenhouse

Technical User
Feb 20, 2000
231
CA
Hi Folks

Two questions here. I occasionally use RS.Edit and get the following error: "Object doesn't support this property or method: 'edit'"

Here's the Code I'm using:

Set RS2 = Server.CreateObject("ADODB.RecordSet")
rs2.cursorlocation = 2

rs2.open sql, DB, 2 ,4

RS2.edit
RS2.Fields("Fname") = Fname
RS2.Fields("LName") = LName
RS2.Update

This is where the other part of my problem comes in, in that I can't use the keywords like adOpenDynamic because it returns a "variable undefined" error. So I'm using the numbers.

Anyway, to get back to my main problem...I use RS.Edit all the time, and most of the time it works great. I can't figure out for the life of me why I'm having this error. It seems to go away just as randomly too....

Any Suggestions or hints would ROCK!

Ben

 
I never use rs.Edit. I just assign the values and then call rs.Update. Take rs.edit out and the update should still work.

As for being unable to use the word "adOpenDynamic", try putting "ADOVBS.INC" into your solution. Use an include file at the top of your asp page referring to "ADOVBS.INC". Then you can use words for your LockType and CursorType instead of numbers.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top