Command Button

P

Paul

What is the VB to open a sheet when a command button is clicked.

I know this is very basic stuff for a lot of you and I do very much
appreciate the help.
 
J

JP

Do you mean to select a sheet, or open a new workbook?

Try something like

Private Sub CommandButton1_Click()
Worksheets("mySheet").Activate
End Sub

or

Private Sub CommandButton1_Click()
Workbooks("C:\mybook.xls").Open
End Sub


HTH,
JP
 
Top