Unprotect Code Module in Code

D

Damien

Can you protect / unprotect a VBA code module in code? eg

ActiveWorkbook.VBProject.VBComponents("Module1").Properties("Password") =
"test"

Thanks
 
C

Chip Pearson

You can't protect a single VBComponent. You can protect only the
entire project, and this cannot be done with VBA (unless you
resort to the dreaded SendKeys).


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com
 
D

Damien

OK Chip,

have you got any examples of doing that with SendKeys? I could try and work
it out but if it's already been done ...
 
Top