Assign Macro

G

Guest

Hello all,
I am using a spreadsheet that has macros. I have created custom tool bar
buttons to launch the macros.

When I assign the macro to the button, it specifically assigns the macro by
spreadsheet path and name!macro name

This is causing problems when I share this document with others, for
example, the button is clicked and it tries to open the macro c:\documents
and settings\David\macro1
No one else has that path and file except me.
is it possible to just use the macro1 within the document and not have the
full file name and macro assigned to a button?
 
T

Tom Ogilvy

No. What you must do is have your workbook create the button each time the
workbook is opened and delete it when it is close.

Or at least have the workbook create the button from the location where it
will reside - or use the onaction property of the button to change the link
to the current location.
 

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