ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Changing the default “macros in all workbooks” (https://www.excelbanter.com/excel-programming/368950-changing-default-%93macros-all-workbooks%94.html)

aca[_17_]

Changing the default “macros in all workbooks”
 

In Excel, when we open several workbooks containing macros, the default
option is that the macros of them all are active; which sometimes
causes a particular macro to act on the wrong file or workbook.
So I have to MANUALLY go to TOOLSMACROS and, in the MACROS IN box
below the list of macros, select the option THIS WORKBOOK instead of the
default ALL WORKBOOKS.
Is there a way of having that default permanently so changed on my
Excel, or of having it changed AUTOMATICALLY on opening the workbook?

Many thanks for any help or tip.
A. C.


--
aca
------------------------------------------------------------------------
aca's Profile: http://www.excelforum.com/member.php...o&userid=25933
View this thread: http://www.excelforum.com/showthread...hreadid=566963


raypayette[_35_]

Changing the default “macros in all workbooks”
 

It seems to me that your code needs to be edited.
The macros' names should be unique.
The sheets and the workbooks should have unique names.
The code should refer to specifiv sheets.
You can use ThisWorkbook.Name in code

--
raypayett

-----------------------------------------------------------------------
raypayette's Profile: http://www.excelforum.com/member.php...fo&userid=2956
View this thread: http://www.excelforum.com/showthread.php?threadid=56696


aca[_18_]

Changing the default “macros in all workbooks”
 

Yes, I see now that my error lies there.
Thank you so much, ray
ACA


--
aca
------------------------------------------------------------------------
aca's Profile: http://www.excelforum.com/member.php...o&userid=25933
View this thread: http://www.excelforum.com/showthread...hreadid=566963



All times are GMT +1. The time now is 06:01 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com