+ Reply to Thread
Results 1 to 2 of 2

If all cells equals a value then format a cell

  1. #1
    Registered User
    Join Date
    06-12-2011
    Location
    London, UK
    MS-Off Ver
    Excel 2007
    Posts
    1

    If all cells equals a value then format a cell

    Please can you help?

    I have a column that contains 3 different value, "P", "F" and "N" - (Pass, Fail and Not Started)

    If ALL cells in the column = "P" then I want a cell underneath to say "Pass"

    If ANY of the cells in the column contain "F" then I want a cell underneath to say "Fail"

    If any cells in the column = "N" then I want the cell underneath to say "Not Started"

    I've searched everywhere but can't find the answer - please help, I'm wearing my function out!!

    Thanks

  2. #2
    Forum Expert teylyn's Avatar
    Join Date
    10-28-2008
    Location
    New Zealand
    MS-Off Ver
    Excel 365 Insider Fast
    Posts
    11,372

    Re: If all cells equals a value then format a cell

    Hello,

    if the values are in cells A1 to A20, then try this formula

    =IF(COUNTIF(A1:A20,"p")=ROWS(A1:A20),"pass",IF(COUNTIF(A1:A20,"n"),"not started ",IF(COUNTIF(A1:A20,"f"),"fail","not all values entered")))

    cheers,

+ 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