User forms

  • Thread starter Thread starter Scott
  • Start date Start date
S

Scott

When you open an Excel worksheet, how do you make
instantly go to a user form?
 
You could have the worksheet activate event open the form.

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)
 
If by sheet you mean workbook, then go into the VBE and in the project
explorer, under the project select ThisWorkbook. double click on it to
display the thisworkbook module. In the left dropdown select Workbook and
in the right dropdown select open (at the top of the module)

This will put in the declaration for the workbook_Open event. Put your code
to display the userform there

Private Sub Workbook_Open()
Userform1.Show
End Sub

Chip Pearson's page on Events:

http://www.cpearson.com/excel/events.htm
 
Thanks for the help
-----Original Message-----
You could have the worksheet activate event open the form.

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)




.
 
Thanks for the help!!
-----Original Message-----
If by sheet you mean workbook, then go into the VBE and in the project
explorer, under the project select ThisWorkbook. double click on it to
display the thisworkbook module. In the left dropdown select Workbook and
in the right dropdown select open (at the top of the module)

This will put in the declaration for the workbook_Open event. Put your code
to display the userform there

Private Sub Workbook_Open()
Userform1.Show
End Sub

Chip Pearson's page on Events:

http://www.cpearson.com/excel/events.htm


--
Regards,
Tom Ogilvy




.
 

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