ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Macro security (https://www.excelbanter.com/excel-programming/334752-macro-security.html)

Ahmed El Hadary[_2_]

Macro security
 
Hi all

I want to make the file when is open make the security level low

thanks

--
Ahmed El Hadary
Financial Analyst
Qatar National Hotels
Mob. 0974-5289491

ddiicc

Macro security
 
Go to TOOLS, MACROS, SECURITY, then choose low

"Ahmed El Hadary" wrote:

Hi all

I want to make the file when is open make the security level low

thanks

--
Ahmed El Hadary
Financial Analyst
Qatar National Hotels
Mob. 0974-5289491


Ahmed El Hadary[_2_]

Macro security
 
thanks alot a know this beffor
ok i want do macro for i but in open file (VBE) and when the file open if
the level securty high
thanks
--
Ahmed El Hadary
Financial Analyst
Qatar National Hotels
Mob. 0974-5289491


"ddiicc" wrote:

Go to TOOLS, MACROS, SECURITY, then choose low

"Ahmed El Hadary" wrote:

Hi all

I want to make the file when is open make the security level low

thanks

--
Ahmed El Hadary
Financial Analyst
Qatar National Hotels
Mob. 0974-5289491


abcd[_2_]

Macro security
 
you mean you wish a macro to do something when macro are not executed ???

This is the idea of security High. You may wait for the user to change
this, but you can not change it by yourself.

BUT you may sign your code and then always accept the signature (in
high level: only signed code may be executed). So your only way is to
sign it...

1- create a local auto sign key pair on your PC: for that purpose go to
the Office folder in Programs and run
....\Microsoft Office\Office\SELFCERT.EXE

2- in the VBA editor, sign your code with your key. (tools menu)

3- make the security level medium, close, reopen the file.
Answer you wish to "always trust this signature..."

4- put again the level high


step 3 and 4 need to be done with each user's PC.

Ahmed El Hadary[_2_]

Macro security
 
Thanks abcd
--
Ahmed El Hadary
Financial Analyst
Qatar National Hotels
Mob. 0974-5289491


"abcd" wrote:

you mean you wish a macro to do something when macro are not executed ???

This is the idea of security High. You may wait for the user to change
this, but you can not change it by yourself.

BUT you may sign your code and then always accept the signature (in
high level: only signed code may be executed). So your only way is to
sign it...

1- create a local auto sign key pair on your PC: for that purpose go to
the Office folder in Programs and run
....\Microsoft Office\Office\SELFCERT.EXE

2- in the VBA editor, sign your code with your key. (tools menu)

3- make the security level medium, close, reopen the file.
Answer you wish to "always trust this signature..."

4- put again the level high


step 3 and 4 need to be done with each user's PC.


Mike Fogleman

Macro security
 
A work around would be to make a "Macro Warning" sheet that has a message to
enable macros to use this workbook. Then hide all the other sheets except
this one. In the Workbook_Open Event, Hide the warning sheet and unhide all
the others. In the Workbook_Close Event, unhide the Warning sheet and Hide
all the others. If macros are not enabled when the book is opened, then the
Workbook_Open event will NOT fire, leaving only the Warning sheet visible.
They must close the workbook, change security to at least Medium, and Enable
Macros when the workbook is re-opened. I know it is a pain in the butt to do
this, but it is much simpler to tell a novice user what to do on a warning
sheet than it is to get them to always accept a Digital Signature.

Mike F
"Ahmed El Hadary" wrote in message
...
Thanks abcd
--
Ahmed El Hadary
Financial Analyst
Qatar National Hotels
Mob. 0974-5289491


"abcd" wrote:

you mean you wish a macro to do something when macro are not executed ???

This is the idea of security High. You may wait for the user to change
this, but you can not change it by yourself.

BUT you may sign your code and then always accept the signature (in
high level: only signed code may be executed). So your only way is to
sign it...

1- create a local auto sign key pair on your PC: for that purpose go to
the Office folder in Programs and run
....\Microsoft Office\Office\SELFCERT.EXE

2- in the VBA editor, sign your code with your key. (tools menu)

3- make the security level medium, close, reopen the file.
Answer you wish to "always trust this signature..."

4- put again the level high


step 3 and 4 need to be done with each user's PC.





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

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