+ Reply to Thread
Results 1 to 7 of 7

Conditional Formatting Issue

  1. #1
    Registered User
    Join Date
    04-05-2010
    Location
    Ohio
    MS-Off Ver
    Excel 2003
    Posts
    3

    Conditional Formatting Issue

    Hello, I am having problems with my conditional formatting. I have 3 columns with about 200 numbers. So for example here is my data:

    C.....D....... E
    100 103 108
    101 102 105
    106 107 104

    Now I want to be able to enter numbers in column "A", which is like user input. The numbers that I will be entering will coincide with a number in one of the columns(so 101, 103, etc).

    I set up 3 conditional formats. I want it to be if the data that is entered is column "C" to turn into a "Red" Color. If the number entered in Column "D" turn green. You get the jist. The problem is the numbers are not in sequential order. So when I enter say "104" it comes up as "red", which is the column "c" color because it is looking at numbers between 100-106, not the numbers themselves.

    Is there a way to do this with a formula? The way I have been doing it is Cell Value Is Between C1-C3, etc etc.

  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: Conditional Formatting Issue

    You could try a formula for the conditional format

    =countif($C$1:$C$100,$A$1)>0

  3. #3
    Forum Expert darkyam's Avatar
    Join Date
    03-05-2008
    Location
    Houston, TX
    MS-Off Ver
    2013
    Posts
    2,191

    Re: Conditional Formatting Issue

    I don't think I quite understand. Will the numbers in C:E be unique (i.e., a number in C will not show up in D or E and so forth)? If so, you can use =COUNTIF(C:C,A1) for the red conditional formatting. If not, please explain the logic of your sheet further, including what formatting takes precedence if the same number is in multiple columns.

  4. #4
    Registered User
    Join Date
    04-05-2010
    Location
    Ohio
    MS-Off Ver
    Excel 2003
    Posts
    3

    Re: Conditional Formatting Issue

    Yeah, each number is unique and will only show up once, so 100 will only be in Column C.

    The reason I am doing this..is at the end of the night I get a list of numbers generated from a program. Those numbers represent a location around the U.S. I have to differentiate the numbers based on the time zone. So Column C is Eastern locations, Column B Pacific locations, Column C Central locations. I want to be able to copy the the numbers from the program, paste them in column a, and have the numbers change colors based off the time zones.

    I tried =countif($C$1:$C$100,$A$1)>0 as my first condition. This works, however, when I add a second condition for column "D" it does not. I did column d as =countif($D$1:$D$100,$A$1)>0. Is that correct or no?
    Last edited by teylyn; 04-05-2010 at 07:56 PM. Reason: removed quote

  5. #5
    Forum Expert darkyam's Avatar
    Join Date
    03-05-2008
    Location
    Houston, TX
    MS-Off Ver
    2013
    Posts
    2,191

    Re: Conditional Formatting Issue

    I think perhaps Teylyn was a bit overzealous with the use of $. Using $A$1 locks the countif onto A1 when you drag it down. You'd want to use A1 or $A1 instead.

  6. #6
    Registered User
    Join Date
    04-05-2010
    Location
    Ohio
    MS-Off Ver
    Excel 2003
    Posts
    3

    Re: Conditional Formatting Issue

    Excellent, Thank you very much guys.
    Last edited by teylyn; 04-05-2010 at 07:56 PM. Reason: removed quote

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

    Re: Conditional Formatting Issue

    You're right, darkyam. I had not picked up on the copy down variety.

    netcat, please don't quote whole posts. It's just clutter.

+ 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