+ Reply to Thread
Results 1 to 3 of 3

Combo-box fails in a protected sheet

  1. #1
    Registered User
    Join Date
    09-24-2006
    Posts
    11

    Question Combo-box fails in a protected sheet

    I am using a validation list-combo box code solution to manage the font size and the number of items that are in the list that is displayed. This works fine while the sheet is not protected. I double click on the cell with the validation list and the combo box code kicks in to display the modified list. When I protect the worksheet, double clicking on the same cell with the validation list does not activate the combo box. The combo box code is attached to the protected sheet. The cell in question is not protected. Can anyone tell me how I can still use this in a protected sheet.

    Thanks

  2. #2
    Forum Contributor Stuie's Avatar
    Join Date
    09-17-2006
    Location
    Suffolk, UK
    MS-Off Ver
    Excel 2003/2007
    Posts
    432
    when using vba code, combo box's ect... it runs on the same principles as normal excel..

    if a sheet is locked u cant used the locked cells so u need to unprotect the sheet to make the adjustment and then protect it again after eg.

    private sub "Name of Sub"()
    Dim sh As Worksheet
    Set sh = Sheets("Sheet1")

    sh.Unprotect "Password1" 'thats if u have a password otherwise leave it off

    'now you can do your normal code here


    sh.Protect "Password1"

  3. #3
    Registered User
    Join Date
    09-24-2006
    Posts
    11
    Thanks..

    I will try this..

+ 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