I have a combo box with a listing of 23 forms.
When the user makes a selection I want to call up the selected form based on
the selected text.
Is it possible to open a form based on a variable for its name
similar to
My_Form.Name = combo1.text
My_Form.show
thanks in advance
Mike
> I have a combo box with a listing of 23 forms.
>
[quoted text clipped - 8 lines]
>
> My_Form.show
I don't think so. The closest you're likely
to get is either:
1) put everything in a Select Case statement:
Select Case combo1.listindex
case 0: form1.show
case 1: form2.show
'
'
case -1: 'nothing was chosen
end select
2) put your forms in a control array, then do:
arrForms(combo1.listindex).show
> thanks in advance
>
> Mike