+ Reply to Thread
Results 1 to 2 of 2

protect sheets allow buttons

  1. #1
    pywhacket
    Guest

    protect sheets allow buttons

    How do I protect a worksheet but allow a control button to work?

    Thank you!

  2. #2
    Candyman
    Guest

    RE: protect sheets allow buttons

    You may want to allow the code to unlock the worksheet...
    Function ThePassword()
    ThePassword = "Excel_1"
    End Function
    Sub Add_Member()
    Dim mName As String
    ActiveWorkbook.Unprotect (ThePassword())
    Worksheets("Template").Unprotect (ThePassword())
    ''' Ask for new name
    mName = InputBox("Enter new member's name.")
    Sheets("Template").Copy After:=Sheets(Sheets.Count)
    <do other stuff>
    Worksheets("Menu").Select
    Worksheets("Template").Protect (ThePassword())
    ActiveWorkbook.Protect
    Exit Sub

    "pywhacket" wrote:

    > How do I protect a worksheet but allow a control button to work?
    >
    > Thank you!


+ Reply to Thread

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