Refrencing a form's combo box in a query

H

HM

Greetings all,

I'm having trouble refrencing a combo box in my form. typically I use a
text box and refrence the text box with [Form name]![field name]
But now I want to use a combo box that pulls info from a small table. And
then use the info selected as my criteria in a query.

I tried simply refrencing the combo box name and that did not work. Any
suggestions on how to call out the combo box in a query criteria?



Thanks in advanced,

HM
 
D

Duane Hookom

You can use Forms!frmName!cboComboName to set your criteria to the bound
column of the combo box. If you want another column to be used, the syntax
is like:
Eval("Forms!frmName!cboComboName.Column(2)")
 
Top