Insert Into

maniaouri

Registered User.
Local time
Today, 10:07
Joined
Sep 4, 2007
Messages
14
I have a very simple question to make:

how I insert into a table or a query the value of textbox or a combobox.I want to use the insert into command. I tried to type the name of the control but it produces the insert value message.

I know the syntax if I write the value in the code but not if Ihave to use a combobox

example:

DoCmd.RunSQL "INSERT INTO [Material category] ( [Material category] ) values (=me.Text6);"

What do I do wrong?
 
do it like this

DoCmd.RunSQL "INSERT INTO [Material category] ( [Material category] ) values (" & me.Text6 & ");"
 
I tried it and it says enter parameter value. I want to do it automatically when i enter the value in the textbox or combobox.
 

Users who are viewing this thread

Back
Top Bottom