Closed Thread
Results 1 to 6 of 6

Locked cells with VBA - wanting ability to filter

  1. #1
    Registered User
    Join Date
    10-01-2008
    Location
    Canada
    Posts
    27

    Locked cells with VBA - wanting ability to filter

    Hi All,

    I asked the question in the past on how to create two buttons so that I can have a data entry specific protection and then a lock all button. Here's the link to the thread:

    http://www.excelforum.com/excel-prog...-a-button.html

    And here's the code I'm currently using:

    Please Login or Register  to view this content.

    Is there anyway that this can be adapted so that when the sheet is "Lock All" protected or if it's "Data Entry" protected that they can still use the filter?

    I've been looking on the site a bit, but haven't had any luck finding anything.

    Thanks for your help!
    Last edited by No.Solutions.; 10-23-2008 at 02:56 PM.

  2. #2
    Forum Expert
    Join Date
    12-29-2004
    Location
    Michigan, USA
    MS-Off Ver
    2013
    Posts
    2,208
    Yes, as long as you are using Excel 2003 or newer.

    Please Login or Register  to view this content.
    HTH

    Jason

  3. #3
    Registered User
    Join Date
    10-01-2008
    Location
    Canada
    Posts
    27
    wow thanks Jason!

    Where did you learn how to use vba so well? I keep looking for online helpers and whatnot but it always seems like gibberish!

    Thanks again!

  4. #4
    Forum Expert
    Join Date
    12-29-2004
    Location
    Michigan, USA
    MS-Off Ver
    2013
    Posts
    2,208
    Glad it helped.

    I think most of my knowledge I learned here, and by working on my own projects. I also read through John Walkenbach's "Excel 2003 Power Programming with VBA". If I had to do it over again, reading that book would be my first step. It explains a lot of the basics before getting into the details.

  5. #5
    Registered User
    Join Date
    09-06-2011
    Location
    Singapore
    MS-Off Ver
    Excel 2007
    Posts
    15

    Re: Locked cells with VBA - wanting ability to filter

    Hi Jason,

    Thanks for this code.
    I however, only want to lock the cells that I indicated as protected, and not the whole worksheet as happens when I use your code.

    By protecting the worksheet however, only for the preselected cells, I still want to keep the autofilter feature for those columns that contain protected cells.

    Could you show me how I have to change the code, so make Excel work this way?

    thanks,
    Alinda

  6. #6
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326

    Re: Locked cells with VBA - wanting ability to filter

    Your post does not comply with Rule 2 of our Forum RULES. Don't post a question in the thread of another member -- start your own thread. If you feel it's particularly relevant, provide a link to the other thread.

Closed 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