unbound combo box shows no value on open

S

smoeller

I have an unbound combo box in a subform to select a project. This subform
contains another subform, that show all the project member. When opening the
main form, the project member of the first project are listed, but the combo
box is empty. I can click the drop down and do see all projects listed and
when selecting a project, it show up in the combo box.
Any ideas how to show the the first projectname when opening the form?
THANKS in advance!
 
K

Ken Sheridan

In the subform's open event procedure put:

Dim ctrl As Control
Set ctrl = Me.cboProject

ctrl = ctrl.ItemData(0)

where cboProject is the name of the combo box.

Ken Sheridan
Stafford, England
 
S

smoeller

THANKS, Ken! It works!!!

Ken Sheridan said:
In the subform's open event procedure put:

Dim ctrl As Control
Set ctrl = Me.cboProject

ctrl = ctrl.ItemData(0)

where cboProject is the name of the combo box.

Ken Sheridan
Stafford, England
 

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.

Ask a Question

Top