G
Guest
Hi,
I am tring to enter the following SQL query in VB. I am recieving
a variable from a combobox, I need the SQL to run the value from
the combobox. The SQL should look up the value and come back with
the corresponding number from that table. All help greatly appreciated,
from an inexperienced user of access and VBA.
Thanks,
Conor.
Dim SQL As String
strManufacturer = Me.Manufacturer.Value
SQL = "Select ManID " & _
"From TabManufacturer.ManID " & _
"WHERE TabManufacturer.Manufacturer = ' & strManufacturer & '"
DoCmd.RunSQL SQL
I am tring to enter the following SQL query in VB. I am recieving
a variable from a combobox, I need the SQL to run the value from
the combobox. The SQL should look up the value and come back with
the corresponding number from that table. All help greatly appreciated,
from an inexperienced user of access and VBA.
Thanks,
Conor.
Dim SQL As String
strManufacturer = Me.Manufacturer.Value
SQL = "Select ManID " & _
"From TabManufacturer.ManID " & _
"WHERE TabManufacturer.Manufacturer = ' & strManufacturer & '"
DoCmd.RunSQL SQL