• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Protect the cells with only selection access no modification...

Irshath

New Member
I have a Protected Excel Dashboard in a Sheet that has some unlocked cells,and those cells have some count(numbers). I have written a macro on 'sheet double click event' If doubleclick on the particular unlocked cell that will take you to the another data sheet and it will automatically filter the data for those numbers.. ... this is not a problem to me.... Actually I have a problem with those unlocked cells to double on that cell they have to select those cells so Ive given Select unlock cell access while protecting the sheet. but they can also change the values of those cells.if i gave this access. that should NOT be ALLOWED........ So please let me know is that any way to protect the cells with only selection option no access to modification... any keypress event like code.in the worksheet change event. or anyother ways to protect the cells from modification.. Please help...


Note: In my office I can't upload any sample workbook.. .. So Please help..
 
You could use application.username


for example


Code:
If Application.Username = My_Username Then 'substitute My_Uesrname for your actual username


or you can use [code]If Not


so basically upon clicking in the cell, a macro will run, check if the username matches the one stored and if not, prevent any change


If you don't know it you can find your username easily by typing


?Application.Username[/code] into the Immediate window in your VBA screen
 
Hi Irshath ,


Can you not protect all cells , and place shapes on top of the relevant cells ; clicking on these shapes can execute the required macro(s).


Narayan
 
Superbbbbbbbbbb,,,, Narayan... This is the thing I want....Great.... Simplest.. way.. Thanks... Thanks a ton... I'll do. that.. :)
 
Thanks Dave.. this is also a nice.. idea.. but i dnt know.. which event Ive to written that code.. thanks .
 
Back
Top