A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Excel » General Discussion
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Password protection/access



 
 
Thread Tools Display Modes
  #1  
Old May 14th, 2009, 08:27 PM posted to microsoft.public.excel.misc
kefee85
external usenet poster
 
Posts: 11
Default Password protection/access

I have a workbook consisting of 14 separate worksheets. I would like for
each department to be able to access only their individual worksheet and two
summary worksheets, but not be able to view the other worksheets.
  #2  
Old May 14th, 2009, 09:15 PM posted to microsoft.public.excel.misc
JBeaucaire[_92_]
external usenet poster
 
Posts: 196
Default Password protection/access

If you mean allow the "access to their sheet and let them change
things"...you'll need some pretty strong VBA code to do that.

If you mean "access their sheet and summary to read only"...then the answer
is simple. PDF files.

I use a free tool called PrimoPDF that installs a printer driver, let's me
create PDF files from inside any program. Create a PDF of their department
sheet and the summaries, send them that.

Our company stopped passing ACTUAL Excel files around years ago and we've
never regretted it.

My two cents... PrimoPDF.com
--
"Actually, I *am* a rocket scientist." -- JB

Your feedback is appreciated, click YES if this post helped you.


"kefee85" wrote:

I have a workbook consisting of 14 separate worksheets. I would like for
each department to be able to access only their individual worksheet and two
summary worksheets, but not be able to view the other worksheets.

  #3  
Old May 14th, 2009, 09:34 PM posted to microsoft.public.excel.misc
Paul C
external usenet poster
 
Posts: 202
Default Password protection/access

If you hide all but the summary sheets and protect the workbook with a
password, you can then put in a auto_open macro to prompt for a password and
unhide sheets based on the response.

You would also need a auto_close macro to hide all of the sheets again for
the next user. You can get much fancier and do a custom form that uses
password characters, but that gets more involved.

In this simple version if the user hit cancel or enters an unrecognized
password no sheets will be unhidden. For added security protect the VBA
project so no one can get to the code and find the workbook password.

Something like this:
Sub Auto_Open()
x = InputBox("Enter Dept Password")

ActiveWorkbook.Unprotect Password:="password"
If x = "accounting1" Then Sheets("Sheet1").Visible = True
'ADD OTHER CONDITIONS

ActiveWorkbook.Protect Password:="password", Structu=True, Windows:=False

End Sub

Sub Auto_Close()
ActiveWorkbook.Unprotect Password:="password"
Sheets("Sheet1").Visible = False
'ADD OTHER SHEETS

ActiveWorkbook.Protect Password:="password", Structu=True, Windows:=False
End Sub
--
If this helps, please remember to click yes.


"kefee85" wrote:

I have a workbook consisting of 14 separate worksheets. I would like for
each department to be able to access only their individual worksheet and two
summary worksheets, but not be able to view the other worksheets.

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 10:38 PM.


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