Forms and List Box

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Help!

I have a form where I created a button called "Select Employees" that once
it's clicked, a new form with a list box will open. The list box contains
'EmpID' 'Last Name' and 'First Name'. I need to somehow have it setup so
that which ever record is selected in the form that has the list box, that it
will populate that EmpID into the parent or original form.

There's no preference on how the EmpID is to be selected, it just needs to
be selected.

Help!!!!!!
 
EA,
Why have a separate form just for selecting an EmployeeID?

1. Make the original EmployeeID field on your main form a ComboBox.
2. Populate via the RowSource query with a list Employee IDs and Names.
FirstColumn = EmployeeID (hidden) SecondColumn = EmployeeName
Column Count = 2
ColumnWidths = 0" ; 1.5" (hides the ID)
ListWidth = 2"

This setup will display a list of EmployeeNames (easiest for users to work with) to
select from, but when a Name is selected, it "displays" that name in the field, BUT... it
really stores the EmployeeID in the EmployeeID field of your table.

On my web site below, I have a 97 and 2003 file (Combo Quick Find) that demonstrates
this combo setup. Although I use the combo to do a record "find" after selection, the
combo "setup" is just the part you need.
 
Back
Top