Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
forcing 'macro enable' on open
Is there a way to essential "force" a user to enable macros by eithe
giving him the choice to enable, or if he doesnt then the workbook i forced to close? In other words, a user cannot edit the workbook without allowing macro enabled. I know that if the wb contains XL4.0 macros and the security level i set to high, then this exact scenario exists... but i cannot ensure th user's Excel security level is set to High -- Message posted from http://www.ExcelForum.com |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
forcing 'macro enable' on open
No, you can't truly force a user to do anything. One possible way that will
work with less sophisticated users is to hide all but the sheets except one, and on that sheet have a message "Hey, only open this workbook with the macros enabled." Then use the workbook open event to hide that 'message' sheet and unhide the others. Password protect everything, including sheets, workbook, and VBA project, so if they open the workbook with macros enabled, they get to see the sheets, otherwise, they only get the message sheet. HTH, Bernie MS Excel MVP "i-Zapp " wrote in message ... Is there a way to essential "force" a user to enable macros by either giving him the choice to enable, or if he doesnt then the workbook is forced to close? In other words, a user cannot edit the workbook without allowing macros enabled. I know that if the wb contains XL4.0 macros and the security level is set to high, then this exact scenario exists... but i cannot ensure the user's Excel security level is set to High. --- Message posted from http://www.ExcelForum.com/ |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
forcing 'macro enable' on open
You can't force a user to enable macros, that would defeat the security
settings. And if macros are disabled, then you can't force the wb to close. What you can do is create a sheet with a statement on it something like "You must enable macros to use this Workbook. Close the Workbook and re-open with macros enabled." In the Private Sub WorkBook_Open() of ThisWorkbook, Hide this sheet and Unhide all the other sheets. In the Private Sub WorkBook_Close() of ThisWorkbook, Hide all the other sheets and unhide this one. This will make only the warning sheet visible when the book is closed. If it is opened with macros disabled, then the WorkBokk_Open cannot run and all they can do is read the warning sheet. Mike F "i-Zapp " wrote in message ... Is there a way to essential "force" a user to enable macros by either giving him the choice to enable, or if he doesnt then the workbook is forced to close? In other words, a user cannot edit the workbook without allowing macros enabled. I know that if the wb contains XL4.0 macros and the security level is set to high, then this exact scenario exists... but i cannot ensure the user's Excel security level is set to High. --- Message posted from http://www.ExcelForum.com/ |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Forcing a workbook to open on a certain page | Excel Discussion (Misc queries) | |||
How can force enable macros to be able to open my workbook? | Excel Discussion (Misc queries) | |||
Forcing a macro to pause for filename | Excel Discussion (Misc queries) | |||
Forcing a macro to (semi-) automatically run | Excel Programming | |||
Forcing users to enable macros | Excel Programming |