Protecting Macro and selected sheets

  • Thread starter Thread starter ST
  • Start date Start date
S

ST

I have written a macro to generate reports in few sheets of a
workbook.Is there a way to prevent users from seeing the macro and at
the same time allowing them to view/edit the rest of the workbook.

Also is it possible to protect selected sheets in a workbook?
 
You can protect your code by doing this within the VBE:

Tools|VBAProject Properties|Protection tab
Lock the project for viewing and give it a memorable password.

You can use tools|protection|protect sheet
but you have to do it one sheet at a time.

(or write a macro that would loop though the selected sheets)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top