Password Protecting a Macro

  • Thread starter Thread starter Marino13
  • Start date Start date
M

Marino13

Is there a way to password protect a macro?

For example, I would like to set up a file that when the file is opened
you cannot view the macros associated with the file unless you have the
password?
 
Marino, you need to protect the VBA project, from your workbook right-click
the workbook's icon and pick View Code. This icon is to the left of the
"File" menu this will open the VBA editor, in the left hand window right
click on your workbook name and select VBA project properties, protection,
check lock project for viewing and set a password. Press Alt and Q to close
this window and go back to your workbook and save and close the file

--
Paul B
Always backup your data before trying something new
Please post any response to the newsgroups so others can benefit from it
Feedback on answers is always appreciated!
Using Excel 97 & 2000
** remove news from my email address to reply by email **
 
Back
Top