PDA

View Full Version : Security Level change



sukumar.vb
08-26-2011, 05:03 PM
I assume that Macro Security Level is set to "high" manually in Workbook.

Using VBA, can I automate this process:-

Menu - > Tools -> Macro -> Security -> Security Level - > Low

(1) Before closing workbook
(2) After Opening workbook

:think:

mikerickson
08-26-2011, 08:25 PM
I don't believe that you can programatically change the security level. That capability runs counter to the concept of security.

sukumar.vb
08-28-2011, 04:49 PM
There is a solution.

GTO
08-28-2011, 05:16 PM
There is a solution.

It may just be me, but that seems unclear. What are you trying to say or ask?

sukumar.vb
08-28-2011, 05:25 PM
Can I change this

Menu - > Tools -> Macro -> Security -> Security Level - > High

to

Menu - > Tools -> Macro -> Security -> Security Level - > Low

(1) Before closing workbook using VBA
(2) After Opening workbook using VBA

Paul_Hossler
08-28-2011, 05:36 PM
Only by doing it yourself manually with your mouse or keyboard

You cannot have VBA do it

Paul

sukumar.vb
08-28-2011, 06:06 PM
I want to see that how many know it.

frank_m
08-28-2011, 10:00 PM
As stated a couple times, macro security settings cannot be changed using code. - A logical part of making something secure, right?

An alternative that proves useful to some programers, is to have code in the workbooks open event that makes it's veryhidden worksheets unhidden if macros are enabled. -- With a visible startup sheet message that notifies the user that they need to change settings to low or medium; save, close and re-open, in order to be able to work with the file.

Here are a couple links for you to read about that.
http://www.excelguru.ca/node/91
The link below, (the last post on the page), is is referred to at the link above, as a "possibly" improved version.(Extensive testing recommended)
http://answers.microsoft.com/en-us/office/forum/office_2007-customize/excel-guru-force-enable-macro-solution-seriously/cdf9885f-f4e3-4424-8fab-7adc541d1c6f

Rob342
08-29-2011, 01:03 PM
I have read a piece by Stephen Bullen, Rob Bovey and John Green

It can be done via VB6.exe using a front loader program, to load excel
its very complicated and a long procedure, involving various class modules etc.

Not for the faint hearted !

Rob

mikerickson
08-29-2011, 03:53 PM
Discussions about how to subvert or avoid Excel's security features are against the rules of this forum.

This thread is closed.