ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   User forms (https://www.excelbanter.com/excel-programming/295460-user-forms.html)

Scott

User forms
 
When you open an Excel worksheet, how do you make
instantly go to a user form?

Bob Phillips[_6_]

User forms
 
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)

"Scott" wrote in message
...
When you open an Excel worksheet, how do you make
instantly go to a user form?




Tom Ogilvy

User forms
 
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

"Scott" wrote in message
...
When you open an Excel worksheet, how do you make
instantly go to a user form?




Scott

User forms
 
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)

"Scott" wrote in message
...
When you open an Excel worksheet, how do you make
instantly go to a user form?



.


Scott

User forms
 
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

"Scott" wrote in message
...
When you open an Excel worksheet, how do you make
instantly go to a user form?



.



All times are GMT +1. The time now is 08:38 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com