Excel VBA open with Password

  • Thread starter Thread starter jlclyde
  • Start date Start date
J

jlclyde

I have a file that I have changed the options to ask for password to
modify. But anyone can open the file as read only. I want to make
changes with a macro to eliminate human error. I want the workbook to
be protected but I need the code to open the file so it can make
changes. How is this accomplished? I tried but this is if it has a
password to open.
Workbooks.Open "G:\DPE-IPE\DPE REVISIONS\New Dpe.xls", Password:="Jay"

Thanks in advance,
Jay
 
Try using: writerespassword:="Jay"

Workbooks.Open "G:\DPE-IPE\DPE REVISIONS\New Dpe.xls", writerespassword:="Jay"
 
Try using: writerespassword:="Jay"

Workbooks.Open "G:\DPE-IPE\DPE REVISIONS\New Dpe.xls", writerespassword:="Jay"

Dave,
Thank you for your keen insight. That fixed it nicely. Do you work
for google? If this is your job, how does one go about getting it?

Thanks,
Jay
 
Nope.

I'm just one of the many volunteers who answer questions in the excel
newsgroups.
 

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