Link to home
Start Free TrialLog in
Avatar of SeanNij
SeanNijFlag for South Africa

asked on

Opening a form based on looked up form name.

Hi all, trust you are keeping well!

Using MS Access 2010. I have a table that has particular values associated to a particular tab name.

1 / MainTab
2 / BookingInTab
3 / QuotationTab

I would like to open a form that contains the tab control and then set the focus to the relevant Tab based on a value that is looked up.

ie.

The lookup returns a "1" and then i would open the form:
Docmd.Openform "FormWithTabControl"

and then

Forms!FormWithTabControl! ( insert looked up tab name here) . SetFocus

How do get the tab name in the above line?

Thanks
Sean
ASKER CERTIFIED SOLUTION
Avatar of peter57r
peter57r
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of SeanNij

ASKER

I can use that to make it work! Fantastic Thankyou