Command button and subform

R

Raj

I have 3 Cmd buttons on my Main Form (Main),(Detail),
(Detail 2). When you click (Detail) or the (Detail)
activates a subform that covers the entire Main form and
allows the user to view and change the information,
(Main) will return you to the Main Form. The problem is
that you have to click the button again to deactivate the
subform ex if I click the (Detail) and then(Main) it will
not return me to the main form until I click(Detail). Is
there a way that once another button is clicked to go to
that form without having to click the button you are
currently on? Thanks in advance
I use this code behind the On Click Private Sub
Cmd49_Click()
If Me.frmDetail.Visible = True Then
Me.frmDetail.Visible = False
Me.Cmd49.Caption = "Detail"
Else
Me.frmDetail.Visible = True
End If

End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top