View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Dianne Dianne is offline
external usenet poster
 
Posts: 107
Default Automate the Userform option

Go to the Visual Basic Editor (Alt+F11).
In the Project Explorer Pane, double-click on the "This Workbook" item.
This will open the code window for the workbook and will create a sub
like this:

Private Sub Workbook_Open()

End Sub

Between these two lines, add
UserForm1.Show (using whatever the name of your form is)

So it ends up looking like this:

Private Sub Workbook_Open()
UserForm1.Show
End Sub

--
Dianne

In ,
Petra typed:
I have developed a userform, and I want the UserForm run
autmatically when the excel workbook is opened. What code
do I use to make work for me.

I would appreciate much any help on matte.
Petra W.