Creating a macro for all future spreadsheets

  • Thread starter Thread starter epicman
  • Start date Start date
E

epicman

I have created a macro however it will only work within that
spreadsheet. How can i write a macro so that all of my documents
(existing and new) can use this macro.

I then wish to assign a button on the toolbar that uses that macro.
 
Store the macro in your personal.xls file. This allows you to use the macro
whenever you have Excel open.
 
I like to work against the activesheet in my code. (Don't use sheet names if
you want it to work for every worksheet.)

Then put the code into a workbook that opens each time excel opens--lots of
people use Personal.xls in their XLStart folder.

And have this workbook build the toolbar modifications when it opens:

For additions to the worksheet menu bar, I really like the way John Walkenbach
does it in his menumaker workbook:
http://j-walk.com/ss/excel/tips/tip53.htm

Here's how I do it when I want a toolbar:
http://www.contextures.com/xlToolbar02.html
(from Debra Dalgleish's site)
 

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

Back
Top