How do i reference the value of a control in a rowsource query?
Im trying to write a query that will pull the value of the selected item in a combobox to use in a WHERE clause.
For example, the user selects "Jeff" out the combobox that is named cboNames. The bound value is 1 (the primary key). I'm trying to create the query:
select * from tbleE开发者_JAVA技巧mployees where empID = cboNames.Value
obviously this doesn't work. Get what I'm trying to do?
How do i place the control value into the query??
select * from tbleEmployees where empID = [Forms]![YourForm]![cboNames]
精彩评论