Insert forms created in excel's visual basic into a worksheet or at startup

W

web_surfer

I have created a form in excel's visual basic.
(I.E. Open Excel, Tool, Macro, Visual Basic Editor)

I have included a picture of where the form is in the Project window i
the left side. The form works great. It even interacts with the exce
file. However, the only way for me to open the form is to enter int
the Visual Basic Editor, find the form I created, then click the Pla
button on the tool bar. Is there anyway to access this form directl
from Excel. Preferably, I would like for it to start only for thi
excel file and I want the form to have a link on the tool bar, so whe
pressed the form starts.

Is there a tutorial on this. I dont think I have created a module. Bu
not sure. Please view the gif file i uploaded for clarity.

The gif. file will show you where the form is that i created.:confused

Attachment filename: forms_insertion_help.gif
Download attachment: http://www.excelforum.com/attachment.php?postid=45405
 
J

Jean-Yves

Hi,
Go back in the VBE
Menu Insert - Module

In that module, create a sub (type):

sub ShowMyForm
myFormName.Show 'myFormName = ...? "UserForm1" if you did not change it
end sub

regards
JY
 

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

Top