Thread: Macro On Open
View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
Dave Peterson Dave Peterson is offline
external usenet poster
 
Posts: 35,218
Default Macro On Open

You could rename that sub to Auto_Open.

As long as it's in a General module (and there isn't an existing sub named
Auto_Open), it should run.

(and if the user allows macros to run)

And if the user can open the workbook, I would bet that the password protection
won't bother the macro. But you'll know for sure when you test it.

wrote:

What code do I need to run a macro when a file is opened? The sub name is
PNL. Also, this file is password protected. Will that affect anything?

Thanks

Adam Bush


--

Dave Peterson