View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 6,953
Default Custom button-lock

If the the workbook with the button is open and you change the workbook that
the button refers to, the reference will adjust. Avoid that condition. If
the workbook with the button is closed, then you can make all the changes you
want and the button will not change.

--
Regards,
Tom Ogilvy


" wrote:

I noticed that when creating a custom button to start a macro it
doesn't always work. Sometime the custom button will be looking at a
different file. Is there anyway to just lock that button to only that
one macro and if it's not in that file then don't run. What's
happening is I move the excel file and then the custom button won't
work. Or if I rename the file the custom button will rename
automatically even if I don't want it to. Basically, if I have two
workbooks which ever is activate the button looks in that notebook and
then neither buttons on both workbooks work correctly. I hope someone
can understand what I'm saying and can help. Thanks