Results 1 to 3 of 3

Protect & unprotect worksheet Macros - supplementary issue

Threaded View

  1. #1
    Registered User
    Join Date
    03-20-2009
    Location
    London, England
    MS-Off Ver
    Excel 2010
    Posts
    56

    Protect & unprotect worksheet Macros - supplementary issue

    All,

    I need further help with this code.

    When I run the protect macro I want only allow users to select unlocked cells for input. I have played around a bit recording another macro and then dumping bits of text into the code that was supplied in answer to my earlier thread but to no avail


    Sub UnprotectAllSheets()
        Dim x As Long
    
        For x = 1 To Sheets.Count
            Sheets(x).Unprotect
        Next x
    
    End Sub
    Sub ProtectAllSheets()
        Dim x As Long
        
        For x = 1 To Sheets.Count
            Sheets(x).Protect
        Next x
    
    End Sub
    What code do I need to add so that I achieve my aim of allowing only unlocked cells to be selected.

    All 14 tabs on the workbook are set with appropriate cells locked/unlocked.

    Thanks for your help in anticipation.

    Best regards,

    David
    Last edited by David_S_Walker; 03-31-2010 at 07:40 AM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1