View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
Mike Middleton Mike Middleton is offline
external usenet poster
 
Posts: 762
Default Bypassing password protection in Visual Basic

Matt -

I don't have an answer to your questions, but I'm following this thread to
learn about the issues.

It would help me understand if you would avoid the word "spreadsheets." An
Excel workbook file contains one or more worksheets. When you write "15
individual spreadsheets," it's not clear to me whether you are referring to
15 workbook files or to one workbook file containing 15 worksheets.

In Excel pre-2007 the Tools menu has a Protection item with two or more
sub-items: Protect Sheet and Protect Workbook, each with an optional
password.

- Mike
http://www.MikeMiddleton.com


"Matt" wrote in message
...
To clarify, I'm talking about the password to open the worksheet. I'm NOT
talking about the password used to protect formatting (Tools - Protection).
If you're referring to the same password, I'm not sure how to disable it in
VB as you described. If there's a way to do it, that's what I need help
with... or any alternative suggestions be great as well.

"Bob Phillips" wrote:

Unprotect the sheet in VBA before working on it, the protect it afterwards

HTH

Bob

"Matt" wrote in message
...
I'm programming a tool for work that is comprised of several different
spreadsheets. There are about 15 individual spreadsheets on a networked
drive and a master spreadsheet that takes and compiles data from the
other
15.

The issue I'm running into is that each of the 15 individual
spreadsheets
is
password protected, so that only the owner of that spreadsheet can
access
it.
I've created a macro on the master spreadsheet that will retreive the
data
from each of the individual spreadsheets, but each time it attempts to
pull
data, it asks for the password.

Is there a way to bypass the password in Visual Basic so that the master
spreadsheet can compile the data from each of the individual
spreadsheets
without it asking for a password? Any help or suggestions would be
appreciated.



.