How to use VBA code in Excel
- selva v pasupathy, HSBC Global Resourcing, Hyderabad
You may find various code snippets in pages of this website, or on a website, and decide to
add it to one of your workbooks. Most code can be added by doing the following:
- Copy the code that you want to use
- Select the workbook in which you want to store the code
- Hold the Alt key, and press the F11 key, to open the Visual Basic Editor
- Choose Insert | Module (to insert a new code module)
- Now you will see the cursor flashing in the code window of a new module that you
inserted. choose Edit | Paste from toolbar.
- Now, hold the alt key, and press F11 key to go back to excel main window.
- To run the code: Choose Tools | Macro | Macros from toolbar
- You will see a popup window with list of macros avialable. Choose the macro that you
want to use and click on run.
9 Comments »
Leave a Comment
You must be logged in to post a comment.
Get FileNames with Path from User « Selva’s Blog said
[...] Get FileNames with Path from User Posted in VBA Examples by selvavpasupathy on October 9th, 2008 HOW SHOULD I USE THE FOLLOWING CODE [...]
Convert Decimal to RGB Color Value « Selva’s Blog said
[...] HOW SHOULD I USE THE FOLLOWING CODE [...]
Clear Controls on Userform « Selva’s Blog said
[...] HOW SHOULD I USE THE FOLLOWING CODE [...]
Convert Case in Excel « Selva’s Blog said
[...] HOW SHOULD I USE THE FOLLOWING CODE [...]
Copy Ranges from Different Sheets into one Sheet « Selva’s Blog said
[...] HOW SHOULD I USE THE FOLLOWING CODE [...]
Automate File Download from Internet « Selva’s Blog said
[...] HOW SHOULD I USE THE FOLLOWING CODE [...]
Display Userform with no Title Bar (Splash Screen) « Selva’s Blog said
[...] HOW SHOULD I USE THE FOLLOWING CODE [...]
Saving userform in Excel as an image « Selva’s Blog said
[...] HOW SHOULD I USE THE FOLLOWING CODE [...]
Displaying A Chart In A Userform « Selva’s Blog said
[...] HOW SHOULD I USE THE FOLLOWING CODE [...]