+ Reply to Thread
Results 1 to 6 of 6

Conditional Formatting Comparing Values in Two Columns

  1. #1
    Forum Contributor meyero90's Avatar
    Join Date
    03-24-2010
    Location
    New York
    MS-Off Ver
    Excel 2007
    Posts
    202

    Conditional Formatting Comparing Values in Two Columns

    Hello guys,

    I am on xls 2007, I have two columns let’s say with data in it. I want to use conditional formatting to be able to do the following and fill the cells based on the following condition:
    IF THE NUMBER IS A1 IS GREATER THAN B1, COLOR IN GREEN, IF FALSE COLOR IN RED.

    Thanks guys.
    Last edited by meyero90; 08-13-2010 at 02:23 PM.
    If I helped, Don't forget to add to my reputation (click on the little scale)
    Don't forget to mark threads as "Solved" (Edit First post>Advanced>Change Prefix)

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

    Re: Conditional Formatting Comparing Values in Two Columns

    Choose Use a formula to determine which cells to format and enter formula =A1>B1

    then click Format and choose Green from Fill tab.

    Click Ok

    Click New Rule and then Use a formula to determine which cells to format and formula:

    =A1<=B1 and click Format and choose Red.
    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.

  3. #3
    Forum Contributor meyero90's Avatar
    Join Date
    03-24-2010
    Location
    New York
    MS-Off Ver
    Excel 2007
    Posts
    202

    Re: Conditional Formatting Comparing Values in Two Columns

    perfect thanks

  4. #4
    Forum Contributor meyero90's Avatar
    Join Date
    03-24-2010
    Location
    New York
    MS-Off Ver
    Excel 2007
    Posts
    202

    Re: Conditional Formatting Comparing Values in Two Columns

    last thing can you help me achieve this, I simulated the results in the attached spreadsheet.
    IF E<G THEN FILL "E" IN GREEN, AND FILL "G" IN RED
    Attached Files Attached Files

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

    Re: Conditional Formatting Comparing Values in Two Columns

    You have to do them seperately, so select the E range and Use a formula to determine which cells to format and enter formula

    then formula: =E9<G9 and Format choose Green

    Then select G range and use same formula: E9<G9 and Format choose Red.

  6. #6
    Forum Contributor meyero90's Avatar
    Join Date
    03-24-2010
    Location
    New York
    MS-Off Ver
    Excel 2007
    Posts
    202

    Re: Conditional Formatting Comparing Values in Two Columns

    Thank you very much NBVC! It worked great!

+ 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