inserting vba into excel

dantb

Active Member
Joined
Mar 20, 2002
Messages
358
New at visual basic. After creating a vbs form, how do you insert it or creat a button to insert it into a excel sheet?
 

Excel Facts

Show numbers in thousands?
Use a custom number format of #,##0,K. Each comma after the final 0 will divide the displayed number by another thousand
In Excel, left click in the toolbar section at the top of the window and select 'Control Toolbox'. You can click on the icons and draw buttons or whatever on your sheet.
 
Upvote 0
I'm sure there are other ways to do this, but here is the way I do it

Create a button, hotkey, picture, or whatever else you can assign a macro to and then show the form from the macro.

If you are not sure how to do this:

Click on your form and check it's properties for the name given if you did not name it yourself. If it is the only form in your project, it will be called form1...

Anyway, in the macro type:
form1.show

Replace form1 with the name you gave your form in necc.
 
Upvote 0

Forum statistics

Threads
1,214,622
Messages
6,120,572
Members
448,972
Latest member
Shantanu2024

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top