Results 1 to 3 of 3
  1. #1
    3 Star Lounger Omega3's Avatar
    Join Date
    Jan 2004
    Location
    Los Angeles, California, USA
    Posts
    343
    Thanks
    2
    Thanked 1 Time in 1 Post

    Select Locked Cells (Excel 2002)

    I use the following code to protect my worksheets:


    For i = 1 To Worksheets.Count
    Worksheets(i).Unprotect Password:=strPasswd
    Next i


    My problem is that the user can still select locked cells even though he can
    You know it's time to diet when you push away from the table and the table moves.

  2. #2
    Platinum Lounger
    Join Date
    Jan 2001
    Posts
    3,788
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: Select Locked Cells (Excel 2002)

    Hi Jim

    When protecting the sheet add the following line.
    <pre>Worksheets(i).EnableSelection = xlUnlockedCells</pre>


  3. #3
    3 Star Lounger Omega3's Avatar
    Join Date
    Jan 2004
    Location
    Los Angeles, California, USA
    Posts
    343
    Thanks
    2
    Thanked 1 Time in 1 Post

    Re: Select Locked Cells (Excel 2002)

    Perfect Tony! In an early post, I think it was your code I found to protect worksheets but didn't know how to lock the cells. I appreciate your help!
    You know it's time to diet when you push away from the table and the table moves.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •