View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Kevin Kevin is offline
external usenet poster
 
Posts: 504
Default assign macro to active workbook??

I have 6 instances of a spreadhseet for different sites. they all have the
same toolbars created and every time you open one it imports the toolbars and
every time you close one it deletes the toolbars. This works good if you
only have one sheet open at a time, but if you have 2 open at the same time
the first one open has the toolbar that refers to that workbook. if you
close thefirst sheet the toolbar stays and the buttons refer to the now
closed wrkbook and if you click one of the buttons it reopends that work book.

Is there a way to have the macros assigned to the buttons as activeworkbook,
instead of the workbook name?