Hi,
is there a sample how to place a frame on the tabstrip? I created a Frame for each Tab.
Andreas
place frames in TabStrip
Re: place frames in TabStrip
Hi,
The TabStrip is a control container, i.e. you can place controls inside it like you can do with a PictureBox or Frame.
So, at first make sure that you place the frames inside the TabStrip and not just on top of it. Then you can connect each tab page with the frame window by using the hAssociatedWindow property:
Now the TabStrip control will make sure that the correct frame is made visible when switching between the tab pages.
Regards
TiKu
The TabStrip is a control container, i.e. you can place controls inside it like you can do with a PictureBox or Frame.
So, at first make sure that you place the frames inside the TabStrip and not just on top of it. Then you can connect each tab page with the frame window by using the hAssociatedWindow property:
Code: Select all
Dim tsTab As TabStripTab
Set tsTab = TabStrip1.Tabs.Add("Tab 1")
tsTab.hAssociatedWindow = Frame1.hWnd
Regards
TiKu
Crunching for Fab36_Folding-Division at Folding@Home. Join Fab36/Fab30! - Folding@Home and BOINC
Boycott DRM! Boycott HDCP!
Boycott DRM! Boycott HDCP!
-
- Cadet
- Posts: 5
- Joined: 04 Oct 2013, 20:13
Re: place frames in TabStrip
Hi Timo,
thanks for help!
BTW: it also works when the frame is outside the tabstrip - but then you have to place it relative to the form.
Andreas
thanks for help!
BTW: it also works when the frame is outside the tabstrip - but then you have to place it relative to the form.
Andreas
Re: place frames in TabStrip
Yes, you're right. For attaching the frames to the tabs, they don't need to be children of the tab control. But you won't get proper theming (with transparent frame background) if the frame controls are not children of the tab control. On the other hand, proper theming is something that works only with my ButtonControls library anyway. So if you use the VB6 frame control, it doesn't matter whether it's a child of the tab control or of the form.Andreas Vogt wrote:BTW: it also works when the frame is outside the tabstrip - but then you have to place it relative to the form.
Regards
TiKu
Crunching for Fab36_Folding-Division at Folding@Home. Join Fab36/Fab30! - Folding@Home and BOINC
Boycott DRM! Boycott HDCP!
Boycott DRM! Boycott HDCP!
-
- Cadet
- Posts: 5
- Joined: 04 Oct 2013, 20:13
Re: place frames in TabStrip
Hi,
I think I found something like a bug.
When I try to set the Tab-Placement it works for TB.TabPlacement = tpTop and TB.TabPlacement = tpBottom
But when I try "tpLeft" or "tpRight" I get the error 382: "Set wird zur Laufzeit nicht unterstützt"
I think I found something like a bug.
When I try to set the Tab-Placement it works for TB.TabPlacement = tpTop and TB.TabPlacement = tpBottom
But when I try "tpLeft" or "tpRight" I get the error 382: "Set wird zur Laufzeit nicht unterstützt"
Re: place frames in TabStrip
It's not a bug. You really cannot change tab placement to one of these two values at runtime. Windows does not allow it.
Crunching for Fab36_Folding-Division at Folding@Home. Join Fab36/Fab30! - Folding@Home and BOINC
Boycott DRM! Boycott HDCP!
Boycott DRM! Boycott HDCP!