+ Reply to Thread
Results 1 to 6 of 6

Complicated Conditional Formating / IF Statement

  1. #1
    Forum Contributor
    Join Date
    02-27-2008
    Posts
    134

    Complicated Conditional Formating / IF Statement

    I don’t know if this is even possible, but I want to conditional format cells with an if statement (something to that nature). I attached an excel file to aid in my question. Basically I want it to be color coded to alert users
    Red if no action is required because info is left out
    Yellow if info is available so take action
    Green if all is complete and nothing needs to be done.

    If G2 does NOT have data then cell H2 has red fill
    If G2 does have data then cell H2 has yellow fill
    And finally if I2 is filled out cells A2:I2 are green filled

    I can’t seem to figure out a start on this. Any help would be appreciated.
    Attached Files Attached Files
    Last edited by Coors; 08-18-2009 at 12:37 PM. Reason: SOLVED -THANKS NBVC

  2. #2
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: Complicated Conditional Formating / IF Statement

    in col h your three formats are
    =$G2="" red
    =AND(ISNUMBER($G2),I2="") yellow
    =AND(ISNUMBER($G2),ISNUMBER($I2)) green
    a2:g2 and I2 need a seperate one of only
    =AND(ISNUMBER($G2),ISNUMBER($I2)) green
    "Unless otherwise stated all my comments are directed at OP"

    Mojito connoisseur and now happily retired
    where does code go ?
    look here
    how to insert code

    how to enter array formula

    why use -- in sumproduct
    recommended reading
    wiki Mojito

    how to say no convincingly

    most important thing you need
    Martin Wilson: SPV
    and RSMBC

  3. #3
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Complicated Conditional Formating / IF Statement

    First select A2:I2 and invoke Conditional Formatting

    Formula Is: =$I2<>""

    click Format and choose Green.

    Click Ok..

    and click Ok to close.

    Now select on H2 and re-invoke Conditional Formatting

    Click Add

    Formula Is: =$G2="" and choose Red.. click Ok

    Click Add

    Formula Is: =$G2<>"" and choose Yellow.. click Ok

    Click Ok to finish.
    Where there is a will there are many ways.

    If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner

    Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.

  4. #4
    Forum Contributor
    Join Date
    02-27-2008
    Posts
    134

    Re: Complicated Conditional Formating / IF Statement

    Quote Originally Posted by NBVC View Post
    First select A2:I2 and invoke Conditional Formatting

    Formula Is: =$I2<>""
    click Format and choose Green.
    Click Ok..
    and click Ok to close.
    Now select on H2 and re-invoke Conditional Formatting
    Click Add
    Formula Is: =$G2="" and choose Red.. click Ok
    Click Add
    Formula Is: =$G2<>"" and choose Yellow.. click Ok
    Click Ok to finish.
    First of all Thanks for the great directions and help. This site has amazing talent.

    Second, everything worked except cell H2 stays yellow, it will not turn green (i attached the excel file as an example) How can I change this.

    Third, I am trying to understand all of this. It all makes sense up until the <> symbols, for example in =$G2<>"" why are the <> included???

    Thanks,
    Attached Files Attached Files
    Last edited by Coors; 08-18-2009 at 12:00 PM. Reason: typo "stays" not says

  5. #5
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Complicated Conditional Formating / IF Statement

    Here is your sheet re-attached and hopefully fixed...

    The <> means does not equal... so in this case check that cell does not equal null (is not empty)....
    Attached Files Attached Files

  6. #6
    Forum Contributor
    Join Date
    02-27-2008
    Posts
    134

    Re: Complicated Conditional Formating / IF Statement

    Works great, thanks for help and explaination

+ 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