Hi
I have a form called x
On this form a text field named Text1
I want to pressa button so that what was written in the Text1 field to go in a table
I did something like this:
Private Sub Commande72_Click()
Dim db As DAO.Database
Dim rc As DAO.Recordset
Dim q As QueryDef
Dim a As String
Set db = CurrentDb
a = Text1
Set q = db.CreateQueryDef("")
q.SQL = "insert into x(descriptionprb) values(here I don't know what to do to pass the a value);"
q.Execute
Thanks for helping
I have a form called x
On this form a text field named Text1
I want to pressa button so that what was written in the Text1 field to go in a table
I did something like this:
Private Sub Commande72_Click()
Dim db As DAO.Database
Dim rc As DAO.Recordset
Dim q As QueryDef
Dim a As String
Set db = CurrentDb
a = Text1
Set q = db.CreateQueryDef("")
q.SQL = "insert into x(descriptionprb) values(here I don't know what to do to pass the a value);"
q.Execute
Thanks for helping