Sheet Protection and sorting

G

Guest

Is there any way to protect a sheet and still allow a user to sort rows? (I posted here b/c figured the solution would involve writing some code)

Here's is what I'm going for: I have worksheet with some cells that are locked and some that are unlocked. I want to restrict a user from deleting rows or columns, but still give them the ability to sort by entire rows (and only entire rows).

Thanks in advance,
Kerry
 
B

beeawwb

I can only offer some slight insights, because I don't think that my wa
of doing things is what you are looking for.

I came across a similar problem when working with Excel 97, in that
had a series of weeks, that were sorted by financial quarter, b
Outlining. Many of these contained formulas that were locked, but th
user still had to be able to enter data, and change the view in outlin
mode (to expose / hide new weeks). What I eventually did was this.

Made code (by way of forums) that checked if a cell was supposed to b
locked, every time you clicked on it. If it was supposed to be locked
it protected the worksheet, by way of the Protect action. If it wasn't
then it checked if the sheet was already locked (If statement) and i
it was, unlocked it, so that views could be changed and data could b
entered.

Possible suggestion for your problem. Define a cell, such as A1, fo
view changing. Make a note that to change sorting, the user must clic
inside this cell. When clicked, the cell unlocks the worksheet, an
sorting is allowed. When unclicked, it resumes it's default protecte
status.

If that solution is acceptable, I think I can work out the code with m
limited knowledge and existing modules.

Hope that ?helps?

-Bo
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top