Protect Macro

  • Thread starter Thread starter K
  • Start date Start date
K

K

Hi all, I have macro in Worksheet module and I have another macro in
normal module which "Move or Copy" the Worksheet which contain the
macro into other files. My orginal file macro is protected but when I
run "Move or Copy" macro and when it transfer the worksheet into other
file then people can see the macro which is in worsheet module. is
there any way that when i run macro to transfer the worksheet into
other file then macro should also protect the worksheet module into
other file. If any body can help it will be much appriciated.
 
You can't protect individual modules of a workbook's project. It's everything
or nothing.
 
You can't protect individual modules of a workbook's project.  It's everything
or nothing.

Thanks for replying Dave. What about if i want whole workbook project
to be protected by vba. is it possible
 
You can protect the workbook's project manually, but there's nothing built into
excel that allows you to do this mechanically.

You could fiddle with Sendkeys, but I've never seen that be an effect way to go.

Maybe you could protect the receiving workbook's project and then when you do
the move or copy, you'll be ok.

If you're moving/copying to a new workbook, then create a workbook template and
protect its project.

Then you can use that template to create a new workbook first. And then
move/copy into that workbook.
 
Back
Top