LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 126
Default Reading Data From Protected WorkBook

The problem is that if the master is password protected,
it prompts the user for the passwordwhen they open their spreadsheet.


The key here is "when they open their spreadsheet"
Are they being asked for a password to their own spreadsheet?
Or
Are they being asked to supply a password for the Master Wbk?

If it is indeed the Master, then you probably have some code in each users
Workbook_Open event that is trying to open the Master as well as the
individual Slave Wbk? What I suggest is that you don't need to have the
Slave Wbk open the Master in order to get data FROM the Master? You can
leave the Master UNopened and just let each user open his/her Slave Wbk and
EXTRACT the data from the unopened Master.

There are several ways of doing this but for starters you might take a look
at this function on the Data menu: DataGet External Data

From a Slave Wbk, try the function, with the Master closed.
Select Excel as the source, then find the Master Wbk from which you want to
extract the data. You will be asked where the data is to be placed in the
Slave Wbk.
Just indicate the upper left cell of a blank sheet or elsewhere as you wish.

When you have tried this manually and found the desired results, turn on the
macro recorder and do it again. The code will be generated for you. For max
efficiency you or someone familiar with VBA will need to streamline the code.

Then make a command button and assign it to this macro.

" wrote:

We will update the master with data every day... We then want the
users to open their version that just has the onesheet that reads from
the master. The problem is that if the master is password protected,
it prompts the user for the passwordwhen they open their spreadsheet.
We need the Master to be password protected so that the users dont open
it or update it.

I am thinking I can use vba in the client workbook to open the password
protected master so that the data can be read. The only problem I am
having is that I am trying to supply the password in the
Workbook_Open() function.... but the clients get promted forthe
master password before this function gets called.

Where should I put the code to supply the password for th Master so it
gets called before it tries to open it?

thanksguys!




 
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
Reading Data from another workbook... depending on variable in a cell? Rob Moyle Excel Discussion (Misc queries) 4 March 13th 06 04:21 PM
Group, Outline, Protected Worksheets and Protected Workbook BEEJAY Excel Programming 0 February 13th 06 08:40 PM
Reading Writing Data from One WorkBook to Another John Pierce Excel Programming 0 May 30th 05 09:23 PM
Open a password protected excel workbook from second workbook to fetch data using dynamic connection kaustav choudhury Excel Programming 2 April 3rd 04 06:18 AM
reading password-protected, open webpage Kevin Excel Programming 7 February 17th 04 09:46 AM


All times are GMT +1. The time now is 03:08 AM.

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

About Us

"It's about Microsoft Excel"