Make visible by on click event

  • Thread starter Thread starter Opal
  • Start date Start date
O

Opal

I have an unbound form with two bound subforms.
The second subform is not visible by default. I
would like to make visible when I click a button
on the first subform. Is this possible? Can
anyone tell me how?
 
Private Sub MyCommandButton_Click()

Me.Parent!Subform2Control.Visible = Not Me.Parent!Subform2Control.Visible

End Sub

Make sure Subform2Control is the name of the subform control on the parent
form. Depending on how you added the subforms, the name of the control may
be different than the name of the form being used as a subform.
 
Sorry Doug, I'm a little confused....

The first subform is "subfrmMSCourse" which contains
the button "cmdOpenDef", when the user clicks this
I want "subfrmMSDeficient" to be visible.

I'm not quite clear how your example, above,
accomplishes this.....?
 
Back
Top