What you're asking MIGHT be able to be done, but it won't be easy.

Excel doesn't HAVE levels of password protection.
It's all User based.

Select all cells in a spreadsheet, Right-click and format Cells.
On Protection tab, select Locked.
then OK button.

When "Protection" is turned on, you can specify that all locked cells
can be selectable, or not selectable.

this has to be done for all sheets.

the problem is:  there is only (1) password.
You CAN create a userform to allow the user to insert the password,
and have it protect the sheet.
However, if the user is allowed to CHANGE the password, then
the Administrator will be locked out and unable to change it.

The only way that I can see around this is to create a hidden sheet,
file or database of some sort that will keep passwords.
(the file could be a binary file, in which you develop some
algorithm to "code" the passwords, so even if someone opened the binary
file, the passwords wouldn't be obvious)
then, allow the user to enter a password that will be validated
from the stored passwords.
Once validated, a macro will unlock the sheet, change the 
locked cells to some pre-defined collection,
then password protect the sheet.

It sounds like this will require some extensive development.

At least, that's what it sounds like to ME, others may know alternatives.

paul


 

________________________________
From: punit poddar <p2pod...@gmail.com>
To: excel-macros@googlegroups.com
Sent: Fri, December 11, 2009 4:45:27 AM
Subject: $$Excel-Macros$$ Fwd: VBA Code for Locking/Unlocking excel sheet using 
password input form

Guys, pls help

---------- Forwarded message ----------
From: punit poddar <p2pod...@gmail.com>
Date: Dec 10, 2009 12:29 PM
Subject: VBA Code for Locking/Unlocking excel sheet using password input form
To: excel-macros@googlegroups.com


Hi

The above file will be used by two person - User and the Administrator, 
administrator can edit anywhere, while the user can edit only in the range 
specified, based on this I have done something in the file attached but would 
help you guys to pls help. Please find attached the excel file.

1. Form that will be used to unlock only the current sheet, it will be better 
if we give the user option to change the password.
2. On closing the file the sheet will automatically gets locked.
3. Have give the user the option to edit only a small range of cells.

Regards
Punit
-- 
----------------------------------------------------------------------------------
Some important links for excel users:
1. Excel and VBA Tutorials(Video and Text), Free add-ins downloads at 
http://www.excelitems.com
2. Excel tutorials at http://www.excel-macros.blogspot.com
3. Learn VBA Macros at http://www.vbamacros.blogspot.com
4. Excel Tips and Tricks at http://exceldailytip.blogspot.com

 
To post to this group, send email to excel-macros@googlegroups.com
If you find any spam message in the group, please send an email to:
Ayush Jain @ jainayus...@gmail.com or
Ashish Jain @ 26may.1...@gmail.com
<><><><><><><><><><><><><><><><><><><><><><>
HELP US GROW !!
 
We reach over 6,500 subscribers worldwide and receive many nice notes about the 
learning and support from the group. Our goal is to have 10,000 subscribers by 
the end of 2009. Let friends and co-workers know they can subscribe to group at 
http://groups.google.com/group/excel-macros/subscribe

-- 
----------------------------------------------------------------------------------
Some important links for excel users:
1. Excel and VBA Tutorials(Video and Text), Free add-ins downloads at 
http://www.excelitems.com
2. Excel tutorials at http://www.excel-macros.blogspot.com
3. Learn VBA Macros at http://www.vbamacros.blogspot.com
4. Excel Tips and Tricks at http://exceldailytip.blogspot.com
 

To post to this group, send email to excel-macros@googlegroups.com
If you find any spam message in the group, please send an email to:
Ayush Jain  @ jainayus...@gmail.com or
Ashish Jain @ 26may.1...@gmail.com
<><><><><><><><><><><><><><><><><><><><><><>
HELP US GROW !!

We reach over 6,500 subscribers worldwide and receive many nice notes about the 
learning and support from the group. Our goal is to have 10,000 subscribers by 
the end of 2009. Let friends and co-workers know they can subscribe to group at 
http://groups.google.com/group/excel-macros/subscribe

Reply via email to