Combo Box to Open Sub

D

DuWayne

I have a main form (Frm_Data_In) and a combo box with
choices (A, B, C, D, E, F, G) which are the names of my
subforms.

When I chose A, B, C, etc... I would like for it to open
the associated subform to enter data and when I select
another choice it close the first form and open the new one.
I hope I made myself clear, still new at this.
 
K

kingston via AccessMonster.com

Use the combo-box's After Update event:

Select Case combo_box_name
Case A
Me.SubFormA.Visible = True
Me.SubFormB.Visible = False
....
Case B
Me.SubFormA.Visible = False
Me.SubFormB.Visible = True
....
Case C
...
End Select

You can stack the subforms on top of each other and control them through
their visible property.
 
Top