Auto-answer Read-Only to Password Dialog pop-up during macro

Asher
2StarLounger
Posts: 169
Joined: 08 Jun 2010, 14:33
Location: Massachusetts, USA

Auto-answer Read-Only to Password Dialog pop-up during macro

Post by Asher »

One of my macro's opens a number of files while it runs. One of these files is Password protected on open. How do I write in my code to click the Read-Only button so it stops interrupting the Macro?

I have attached a pic of the Dialog Box.
pwordDialogDuringEVMacro.JPG
You do not have the required permissions to view the files attached to this post.

User avatar
rory
5StarLounger
Posts: 817
Joined: 24 Jan 2010, 15:56

Re: Auto-answer Read-Only to Password Dialog pop-up during macro

Post by rory »

Have you tried specifying the ReadOnly:=True argument when opening the file?
Regards,
Rory

Asher
2StarLounger
Posts: 169
Joined: 08 Jun 2010, 14:33
Location: Massachusetts, USA

Re: Auto-answer Read-Only to Password Dialog pop-up during macro

Post by Asher »

Thanks Rory! That works!