Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Tab Control Will Not Embed Another Tab Control

Status
Not open for further replies.

Johnnycat1

Programmer
May 4, 2005
71
US
This is driving me nuts! I have a simple form with a two tab tab control. I have another tab control form that I need to embed in the first tab of the main tab control. I have done this successfully multiple times but for some reason I cannot create a new tab control inside the main tab control and I cannot paste the tab control that I have already created in the main tab control either. I am selecting the tab that I want to insert the "sub" tab control into, right clicking and hitting paste and it will not embed in the main tab control.

I can solve this with code but I want to understand what is going on here.

Any help would be very appreciated!

nanos gigantum humeris insidentes

A dwarf on the shoulders of giants...
 
Are you sure you have done this before? AFAIK that is not possible. I do not have Access here to verify. You can put a subform on a tab with a tab control in the subform thus giving the appearance and potentially achieving the same results. What are you trying to do? That sounds like a very confusing interface. There may be a cleaner approach. If you got the code to do this, I would be interested in seeing that.
 
So looking back at my various databases, I see that I have not used this before. The interface is actually quite simple because the main TabControl is the full screen of the main form and the first tab is the data entry form and the second tab has the reporting with some report filtering fields. The sub-TabControl is just two logical sets of form fields.

The code that I use is just quick and dirty. It hides and unhides the sub TabControl on the OnChange event procedure.

If Forms![FrmRFI]![TabCtl149].Visible = True Then Forms![FrmRFI]![TabCtl149].Visible = False Else Forms![FrmRFI]![TabCtl149].Visible = True

Not sexy but it works. The obvious limitation is that the main TabControl can only have two tabs.

Thanks for your post.

nanos gigantum humeris insidentes

A dwarf on the shoulders of giants...
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top