Concatenate its value into an SQL string that you build in code.
or
Write a public function that reads the value in the combo box and returns it
as the value of the function; call this function from a query (assumes that
you're running the query in the ACCESS front end).
For numeric fields:
strSQL = "SELECT * FROM MyTable WHERE [FieldName]=" & Me.ComboboxName.Value
For text fields:
strSQL = "SELECT * FROM MyTable WHERE [FieldName]='" & Me.ComboboxName.Value
& "'"
--
Ken Snell
<MS ACCESS MVP>
Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.