Switchboard Button

  • Thread starter Thread starter Beeyen
  • Start date Start date
B

Beeyen

Good Day,

I have a form with five tabs. I have a switchboard with four command
buttons but would like one of the command buttons to open without being able
to see one of the tabs in the form. Is there a way to do this?

I tried the coding below in the form but the tab was removed for all of the
command buttons or anytime you open the form.

Private Sub Form_Activate()
Me.(Name of the Tab).visible=False

End Sub

Thank for your assistance
 
On your commandbutton click event on the Switchboard form:
Private Sub Command0_Click()
DoCmd.openform "Your form name", , , , , , "A" 'this can be anything you
want
End Sub

On your form open event with the tabs:

If Me.OpenArgs = "A" Then
Me.[YourTabName].Visible = False
End If


Damon
 
Thanks,

It worked!

Have a nice evening.

Damon Heron said:
On your commandbutton click event on the Switchboard form:
Private Sub Command0_Click()
DoCmd.openform "Your form name", , , , , , "A" 'this can be anything you
want
End Sub

On your form open event with the tabs:

If Me.OpenArgs = "A" Then
Me.[YourTabName].Visible = False
End If


Damon



Beeyen said:
Good Day,

I have a form with five tabs. I have a switchboard with four command
buttons but would like one of the command buttons to open without being
able
to see one of the tabs in the form. Is there a way to do this?

I tried the coding below in the form but the tab was removed for all of
the
command buttons or anytime you open the form.

Private Sub Form_Activate()
Me.(Name of the Tab).visible=False

End Sub

Thank for your assistance
 
Back
Top