Password protected
Good day.
I have a Excel file that links back to several other files. However, some of the other files are password protected. If I know the passwords, it is possible to pass those password using VBA and open my linked workbook without being prompted for a password? Each time I open the linked file I am asked for the passwords to the other files, but the users don't want that. They do want their files protected, however. Any ideas? |
Password protected
Hi Steve,
Look in the online help for the Open method of the Workbooks collection, you can use the following parameters: " Password -- Optional Variant. A string that contains the password required to open a protected workbook. If this argument is omitted and the workbook requires a password, the user is prompted for the password. WriteResPassword -- Optional Variant. A string that contains the password required to write to a write-reserved workbook. If this argument is omitted and the workbook requires a password, the user will be prompted for the password. " so Workbooks.Open Filename:="C:\mybook.xls", password:="mypass" ,... -- Regards, Sébastien <http://www.ondemandanalysis.com "Steve" wrote: Good day. I have a Excel file that links back to several other files. However, some of the other files are password protected. If I know the passwords, it is possible to pass those password using VBA and open my linked workbook without being prompted for a password? Each time I open the linked file I am asked for the passwords to the other files, but the users don't want that. They do want their files protected, however. Any ideas? |
Password protected
Sorry, let me rephrase the question. I don't want to open the linked files,
I just don't want to see the password dialog come up for each file that is linked to this workbook. In other words, for each file that is linked to the main file, if the file is closed, I have to type the password just to get the files to link. I just want them to link without typing the password for each file. I know the passwords for each file and I want to use them in VBA to link the protected files, but not open them. Make sense? "sebastienm" wrote: Hi Steve, Look in the online help for the Open method of the Workbooks collection, you can use the following parameters: " Password -- Optional Variant. A string that contains the password required to open a protected workbook. If this argument is omitted and the workbook requires a password, the user is prompted for the password. WriteResPassword -- Optional Variant. A string that contains the password required to write to a write-reserved workbook. If this argument is omitted and the workbook requires a password, the user will be prompted for the password. " so Workbooks.Open Filename:="C:\mybook.xls", password:="mypass" ,... -- Regards, Sébastien <http://www.ondemandanalysis.com "Steve" wrote: Good day. I have a Excel file that links back to several other files. However, some of the other files are password protected. If I know the passwords, it is possible to pass those password using VBA and open my linked workbook without being prompted for a password? Each time I open the linked file I am asked for the passwords to the other files, but the users don't want that. They do want their files protected, however. Any ideas? |
All times are GMT +1. The time now is 08:21 AM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com