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!

ADO Stuff

Status
Not open for further replies.

damann

Technical User
Jul 19, 2000
114
US
Hey guys,

I have an opened recordset that is already connected to a database called conn. I want to add data from a form to this recordset. Which would be the correct way of doing this?

1. conn("Date") = yr
2. conn.Fields("Date") = yr
3. conn.Field("Date") = yr

Explain.

Thank you,
Damman
 
sorry guys, the "recordset" is called conn not the database...
 
First you got to do an addnew like:

conn.AddNew
conn.Fields("Date").Value = yr
conn.Update

set conn = nothing
....

The CursorType of your reccordset must be adopenKeyset or adOpenDynaset.

Good luck, s-)

Blessed is he who in the name of justice and goodwill, sheperds the weak through the valley of darkness...
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top