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

Updata Data in a grid

Status
Not open for further replies.

Cloonalt

Programmer
Jan 4, 2003
354
0
0
US
I have a form with a field box and a third party grid control. Data is keyed into the field and then updates the grid, resulting in a list of data in the grid. Grid name is ssQueued.

Can someone point me to some code that will update the database with the data that's in the grid.

Any help appreciated.
 
Cloonalt

If the data transfered to the grid has to update the database (not second thinking: "Should I stay or should I go?"), then

strSQL = "INSERT INTO myTableName(myFieldName) " & _
"VALUES '" & txtAddData & "'"
obj.execute strSQL

as the next statements to be executed after your adding to the grid.

obj is an already open connection to your mdb, or the well know CurrentProject.Connection, in case of ADO. For DAO obj should be CurrentDB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top