views subform on tab control (page 1)

  • Thread starter Thread starter lgordon
  • Start date Start date
L

lgordon

Hi:
I am having problem try to make visible, a subform whose
visible property was set to false when the main form first
open. On the tab control there are two pages, on page0 I
have the visible property set at zero. On page1, whenever
the tab is click(selected), I have the visible property
value set to true, but the subform does not show. Can
someone please help me here.

Thank You,
L. Gordon.
 
L,

I am not sure what the specific problem can be. But I am puzzled why
you are manipulating the Visible property of the subform anyway. If
your subform is positioned on Page1 of the Tab Control, then if Page0 of
the Tab Control is the selected page, then Page1 (and hence the subform)
will not be visible anyway. Maybe you in fact have the subform
positioned on the main form, "underneath" the tab control, rather than
positioned on the tab control itself? In design view of the form, if
you move the tab control aside, do you then see the subform? Or, again
in design view, if you select the tabs of the tab control one at a time,
do you see the subform on Page1 but not on Page0?
 
-----Original Message-----
L,

I am not sure what the specific problem can be. But I am puzzled why
you are manipulating the Visible property of the subform anyway. If
your subform is positioned on Page1 of the Tab Control, then if Page0 of
the Tab Control is the selected page, then Page1 (and hence the subform)
will not be visible anyway. Maybe you in fact have the subform
positioned on the main form, "underneath" the tab control, rather than
positioned on the tab control itself? In design view of the form, if
you move the tab control aside, do you then see the subform? Or, again
in design view, if you select the tabs of the tab control one at a time,
do you see the subform on Page1 but not on Page0?

--
Steve Schapel, Microsoft Access MVP


.
Hi Steve:
I am manipulating the visible property through the OnClick
event on the tab, and initially setting it to false during
OnOpen event of the main form. Things seems messy here. I
move the Tab like suggested in Design View, and I do see
the subform on the main form, but I also see it on each
pages of the Tab control. Also, without the code, the
subform is visible on both pages of the tab control, when
in form view.

L. Gordon.
 
L,

Ok. As intimated in my earlier post, forget the idea of toggling the
subform's Visible property. Your subform has not been correctly
positioned. I suggest start from scratch. Delete the subform from the
form. In design view, click the tab on the tab control for Page1 (if
that's where you want the subform to show). Drag the form you are using
for the subform from the database window, and hen your mouse pointer
gets over the tab control, the background of the tab control should
change colour to indicate you are in the right place. Drop your subform
at this point. After this, the subform will only be seen when the tab
control's page is selected.
 
-----Original Message-----
L,

Ok. As intimated in my earlier post, forget the idea of toggling the
subform's Visible property. Your subform has not been correctly
positioned. I suggest start from scratch. Delete the subform from the
form. In design view, click the tab on the tab control for Page1 (if
that's where you want the subform to show). Drag the form you are using
for the subform from the database window, and hen your mouse pointer
gets over the tab control, the background of the tab control should
change colour to indicate you are in the right place. Drop your subform
at this point. After this, the subform will only be seen when the tab
control's page is selected.
Hi Steve:
Thanks for your help, that's exactly what I did,
and that works for me.

L. Gordon.
 
Back
Top