View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Chip Pearson Chip Pearson is offline
external usenet poster
 
Posts: 7,247
Default Open workbook that is protected with password

Ian,

You can include the password in the Open method. E.g.,

Workbooks.Open Filename:=Path & Filename, Password:=Password


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


"ianripping " wrote
in message ...
Hi I have a workbook that is saved with a password.

I want to create a macro that will opne up this file because it

knows
the password, eg:

Dim password
password = "letmein"
Dim path
Dim filename
Workbook.open = path & filename 'With password!

Can anyone help with this?


---
Message posted from http://www.ExcelForum.com/