Excel 97 - Password protect VBA Code

  • Thread starter Thread starter beeawwb
  • Start date Start date
B

beeawwb

Regarding my previous post on putting a password into m
ActiveSheet.Protect in VBA code, I now need to password protect the VB
code so that you couldn't just load up the worksheet modules and vie
what the unlocking password was. Is there any way to lock off the VB
code so that only I may view / change it?

Thanks for reading. :)

-Bo
 
You can Protect your project in the VBA editor

Alt-F11
In the menubar Tools>VBA project properties
See the protection tab

This way they can't see or edit your code
 
Bob

Open VBEditor(ALT + F11)

Right-click on your project name.

Select Properties>Protection. File must be saved/closed and re-opened for
protection to take effect.

Note: Excel protection can be broken by someone if they know how to surf the
'net for password-crackers.

Gord Dibben Excel MVP
 
Perfect. That works exactly how I wanted it to. I had discovered the
password tab, but hadn't closed the document and reopened it, hence why
it wasnt working for me.

Thanks heaps for the help. :)

-Bob
 
Back
Top