![]() |
Include password in VBA code to open file problem
Hi I have a workbook that is initially opened by the user with a modifying password. Then when a macro is run I want to be able to close and then re-open this workbook without having to input the password again. I have tried: Workbooks.Open Filename:="D:name.xls", Password:="My_Password" but I am still asked to enter the password. How do I do this? Paul -- PaulC ------------------------------------------------------------------------ PaulC's Profile: http://www.excelforum.com/member.php...fo&userid=7563 View this thread: http://www.excelforum.com/showthread...hreadid=274042 |
Include password in VBA code to open file problem
Your code worked for me, I'm running Excel ver 10.0 (OfficeXP).
Most Microsoft software is case sensitive when entering a password. Check the way you've entered the password in your code. -- Donald "PaulC" wrote in message ... Hi I have a workbook that is initially opened by the user with a modifying password. Then when a macro is run I want to be able to close and then re-open this workbook without having to input the password again. I have tried: Workbooks.Open Filename:="D:name.xls", Password:="My_Password" but I am still asked to enter the password. How do I do this? Paul -- PaulC ------------------------------------------------------------------------ PaulC's Profile: http://www.excelforum.com/member.php...fo&userid=7563 View this thread: http://www.excelforum.com/showthread...hreadid=274042 |
All times are GMT +1. The time now is 05:05 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com