Command Button

  • Thread starter Thread starter Paul
  • Start date Start date
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.
 
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
 

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

Back
Top