Reputation: 53
I know that a vba macro can be password protected. I was wondering if the same could be applied to an event change macro? If yes then how would you go about it.
Upvotes: 1
Views: 2599
Reputation: 2355
"To protect your code, open the Excel Workbook and go to Tools>Macro>Visual Basic Editor (Alt+F11). Now, from within the VBE go to Tools>VBAProject Properties and then click the Protection page tab and then check "Lock project from viewing" and then enter your password and again to confirm it. After doing this you must save, close & reopen the Workbook for the protection to take effect."
Source: http://www.ozgrid.com/VBA/protect-vba-code.htm
This was an easy google, I reccomend you look online before asking on Stack Overflow, these simple questions are generally not well received.
If your question is about protecting a specific part of your code, and not the other parts of the code, then it can't be done as far as I know.
Upvotes: 1