Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 21
Default testing for password protection

Thanks, no need to worry then.

"Jacob Skaria" wrote:

If you only have the open password; then supply passwords for all workbook
open statements and Excle will ignore if the workbook do not have a
password....

Dim strPassWord

strPassWord = InputBox("Enter password for your workbooks")
'workbook with password
Workbooks.Open "d:\temp.xls", Password:=strPassWord

'workbokk without password
Workbooks.Open "d:\temp1.xls", Password:=strPassWord


--
Jacob (MVP - Excel)


"Hakyab" wrote:

Is there a way to check whether a workbook requires a password to open, prior
to opening the workbook?

What I want to do is to capture the password as the user enters it so I can
use the password for subsequent workbooks.open statements. I thought that my
module will prompt for the password, but I am not sure how this will behave
if there is no password to begin with.

Any help is appreciated, thanks.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Password protection in macro ( Anybody can view my password in VB Sherees Excel Discussion (Misc queries) 2 January 24th 10 10:05 PM
Excel Data Protection- AKA: Sheet/Macro Password Protection Mushman(Woof!) Setting up and Configuration of Excel 0 December 29th 09 06:50 AM
Password Protection JamesD Excel Discussion (Misc queries) 1 April 7th 05 02:36 PM
Testing If password is being cracked? Winshent Excel Programming 1 October 7th 04 01:09 PM
Password protection series0 Excel Programming 1 February 12th 04 01:10 AM


All times are GMT +1. The time now is 07:47 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"