Query used with combo box

  • Thread starter naiveprogrammer
  • Start date
N

naiveprogrammer

I need to write a query that would be based off of what kind of training
someone has. My information is stored as 1's & 2's as it is entered from a
data entry form that contains option buttons. Basically there are two kinds
of training- OSHA or CPR/First Aid. OSHA is stored as a 1 in my table and
CPR/First Aid is stored as a 2.

Here is where I get lost- I want a combo box that drops down with a value
list I would assume naming either choice- OSHA or CPR/First Aid. When you
choose OSHA it will show you all the people that has OSHA training and vice
versa. I have my form set up with my combo box with this code for the search
button: Code:
--------------------------------------------------------------------------------

Private Sub cmdSearch_Click()DoCmd.OpenForm "frmTrainingDE", , ,
"[TypeOfTraining]=" & Me.Combo5DoCmd.Close acForm, Me.NameEnd Sub
--------------------------------------------------------------------------------


I'm not sure how to write the query to get the results I'm wanting.

My table name is- tblEmp
Field where the option buttons are stored- TypeOfTraining

I hope this makes sense! Thanks!
 
Top