Open Workbook with P/W using VBA

  • Thread starter Thread starter Damian Lee
  • Start date Start date
D

Damian Lee

I want to open a workbook within some code but the
workbook has a passsord that needs to be entered. The
file needs to be opened for the users so that data will
update and then close the file. Any idea how to include
the password as part of the code?

Thanks ahead of time
Damian
 
Workbooks.Open "c:\my documents\myworkbook.xls", Password:="mypassword"
 

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