ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Protection property of the VBA project (https://www.excelbanter.com/excel-programming/336781-protection-property-vba-project.html)

helmekki[_89_]

Protection property of the VBA project
 

Hi there

Is there a vba code to check the Protection property of the VBA projec
in a an Excel File ?.

So that a MsgBox tells me that the VBAProject is protecte

--
helmekk

-----------------------------------------------------------------------
helmekki's Profile: http://www.excelforum.com/member.php...nfo&userid=693
View this thread: http://www.excelforum.com/showthread.php?threadid=39418


Jim Rech

Protection property of the VBA project
 
MsgBox Workbooks("Book1.xls").VBProject.Protection = vbext_pp_locked

returns true if the project is locked.

--
Jim
"helmekki" wrote in
message ...
|
| Hi there
|
| Is there a vba code to check the Protection property of the VBA project
| in a an Excel File ?.
|
| So that a MsgBox tells me that the VBAProject is protected
|
|
| --
| helmekki
|
|
| ------------------------------------------------------------------------
| helmekki's Profile:
http://www.excelforum.com/member.php...fo&userid=6939
| View this thread: http://www.excelforum.com/showthread...hreadid=394181
|



Jim Rech

Protection property of the VBA project
 
Use a 1 in place of vbext_pp_locked if you do not have a reference set to VB
extensibility.

--
Jim
"helmekki" wrote in
message ...
|
| Hi there
|
| Is there a vba code to check the Protection property of the VBA project
| in a an Excel File ?.
|
| So that a MsgBox tells me that the VBAProject is protected
|
|
| --
| helmekki
|
|
| ------------------------------------------------------------------------
| helmekki's Profile:
http://www.excelforum.com/member.php...fo&userid=6939
| View this thread: http://www.excelforum.com/showthread...hreadid=394181
|



helmekki[_90_]

Protection property of the VBA project
 

It greatly worked fine

Thank u very much indeed


--
helmekki


------------------------------------------------------------------------
helmekki's Profile: http://www.excelforum.com/member.php...fo&userid=6939
View this thread: http://www.excelforum.com/showthread...hreadid=394181



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

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