Setting value in unbound table

  • Thread starter Thread starter Junior
  • Start date Start date
J

Junior

Using VBA in the Form open event
How could i set a value in
[tblOne]. [fieldOne]

where [fieldOne] is integer from a
form [FormOne] that is not bound to [tblOne]
Thanks
 
-----Original Message-----
Using VBA in the Form open event
How could i set a value in
[tblOne]. [fieldOne]

where [fieldOne] is integer from a
form [FormOne] that is not bound to [tblOne]
Thanks


The following code could actually be placed anywhere, on a
button's Click event or whatever.

strSQL = "INSERT INTO tblOne (fieldOne) VALUES (" & intOne
& ")"
DBEngine.Workspaces(0).Databases(0).Execute strSQL

Obviously, your SQL statement could be as complex or
simple as required.
 
Back
Top