+ Reply to Thread
Results 1 to 8 of 8

Prevent cells selction of conditionally formatted hidden cells

  1. #1
    Registered User
    Join Date
    09-03-2010
    Location
    London, England
    MS-Off Ver
    MS EXCEL 365 (v. 2111)
    Posts
    41

    Prevent cells selction of conditionally formatted hidden cells

    Hi Guys

    I have created a spreadsheet to allow our admin guys to input customer and order information which then feeds through onto a 'Pro Forma Invoice', a 'Welcome Letter' and a 'Bank Letter' (see attached)

    I have conditionally formatted the input screen so that if Payment Method (top right) says anything but PM 5 (Installments), the 'Standing Order' section disappears.

    The problem i have is that you could still select the cells (by mistake) and in doing so affect the other sheets. Is there a way to prevent users selecting a cell if it is hidden by conditional formatting?

    Thank you for your help in advance.
    Attached Files Attached Files

  2. #2
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,429

    Re: Prevent cells selction of conditionally formatted hidden cells

    The sheet is password protected but I suspect you could use Data Validation on those cells. It won't prevent the cells being selected but it could stop data being entered.

    Use Custom with the formula: =AY4="PM 5 (Installments)"

    Regards
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  3. #3
    Forum Guru (RIP) Marcol's Avatar
    Join Date
    12-23-2009
    Location
    Fife, Scotland
    MS-Off Ver
    Excel '97 & 2003/7
    Posts
    7,216

    Re: Prevent cells selction of conditionally formatted hidden cells

    A password protected sample isn't the handiest way to get your solution.

  4. #4
    Registered User
    Join Date
    09-03-2010
    Location
    London, England
    MS-Off Ver
    MS EXCEL 365 (v. 2111)
    Posts
    41

    Re: Prevent cells selction of conditionally formatted hidden cells

    Sorry Guys, i thought i checked every page - clearly not!
    Attached Files Attached Files

  5. #5
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,429

    Re: Prevent cells selction of conditionally formatted hidden cells

    Yes:

    Custom - Formula: =$AY$4="PM 5 (Installments)"

    On the cells you want to avoid entry

    Note the absolute reference rather than my first post

    Regards

    By the way, the sheet was still protected

  6. #6
    Registered User
    Join Date
    09-03-2010
    Location
    London, England
    MS-Off Ver
    MS EXCEL 365 (v. 2111)
    Posts
    41

    Re: Prevent cells selction of conditionally formatted hidden cells

    Thank for that - worked great.

    I do have a problem however, the cell in question has already got data validation in it in the form of a list.

    Is it possible to apply multiple data validations to one cell?

  7. #7
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,429

    Re: Prevent cells selction of conditionally formatted hidden cells

    I'll have to pass on that ... beyond my level of expertise (at this point in time).

    I will experiment, but gut reaction is that it could be difficult.

    In the meantime, you could apply the validation to the other cells where you input the address, etc., which could avoid some issues.

    Regards

  8. #8
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,429

    Re: Prevent cells selction of conditionally formatted hidden cells

    OK, I can't find a way to use two types of validation but ...

    Change BN13 to =IF($AY$4="PM 5 (Installments)",ROW(BN13)-ROW($B$12),"")

    And drag down to BN24 (your Installment validation list (inst))

    What this will do is set the list to blanks (nulls) so, if you do manage to find that cell you will have nothing to select. You WILL still get a list but all the entries will be blank.

    I like the way you've done this but I would be inclined to have the validation lists on a separate hidden control sheet ... personal choice though and it works nicely as it is.

    Regards

    Regards

+ 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