run a user form from a macro.


Posted by andy evans on November 12, 2001 2:12 AM


Help!

Having created a user form with a combobox using the code supplied in vb help I cannot find a way of making a macro run the user form. The form works fine if you simply run it.

The help section does not explain clearly simply saying use run sub/user form. I have tried every variation of this command that I can think of within a macro but it does not run the form.

The code for the form starts private sub user form_initialize()

How do I get the macro to call this?

Anyone?

Andy Evans



Posted by Rick E on November 12, 2001 6:16 AM

Use the Show method, as in:

Sub showForm()
UserForm1.Show
End Sub

Good Luck with your Excel-ing