+ Reply to Thread
Results 1 to 4 of 4

How do I write a formula to color code based on dates provided or.

  1. #1
    jaime
    Guest

    How do I write a formula to color code based on dates provided or.

    I am trying to do the following: If a date is in cell A1, B1, C1 and then I
    would like to have D1 color codes green, if a date is in A1 and B1 and
    nothing in C1 I would like cell E1 to be colored yellow and so on.

    I work for a business and we will be using a date table to show the progress
    of a project. We are looking for a simple way to show the status of each
    project by using colors. Red meaning urgent, green OK and yellow some work
    still needed.

    Anyone have any suggestions?

  2. #2
    Registered User
    Join Date
    02-04-2005
    Posts
    8

    See if I am understanding correctly

    If a date is in A1, B1, and C1, then you want D1 to be green.

    If a date is A1, B1, and C1 is blank, then you want E1 to be yellow

    If there are no dates or just a date is A1, then I assume you want F1 to be red.

    I can provide a couple solutions to this. I am not sure if you need to use D1, E1, and F1; a simpler solution would be to just use D1 as the color coded cell.

    Put the following formula into cell D1: =Count(A1:C1)

    Now you will need to use Excel's conditional formatting feature located under the format menu. If the value in cell D1 is equal to 3, then change the formatting pattern to green. Now add another condition, if the value in cell D1 is equal to 2, then change the formatting pattern to yellow. Again add another condition and if D1 is less than or equal to 1 then change the formatting pattern to red.

    If you need to use cells D1, E1, and F1 as the color coded cells and not just use D1. Then you need to put the count function into each of these cells. Then bring up conditional formatting and set the cell equal to 3 for D1 and formatting to green; equal to 2 for E1 and yellow; and less than or equal to 1 for F1 and red.

    Let me know if this makes sense and works for you.

  3. #3
    Jason Morin
    Guest

    Re: How do I write a formula to color code based on dates provided or.

    You can apply conditional formatting to 1 or more cells,
    and have them change color depending upon the results in
    other cells. Using your first request as an example,
    select D1, go to Format > Conditional Formatting,
    select "Formula Is" on the drop-down and insert:

    =COUNT($A$1:$C$1)=3

    Press the Format radio button and format as desired. To
    learn more, see:

    http://www.contextures.com/xlCondFormat01.html

    HTH
    Jason
    Atlanta, GA

    >-----Original Message-----
    >I am trying to do the following: If a date is in cell

    A1, B1, C1 and then I
    >would like to have D1 color codes green, if a date is in

    A1 and B1 and
    >nothing in C1 I would like cell E1 to be colored yellow

    and so on.
    >
    >I work for a business and we will be using a date table

    to show the progress
    >of a project. We are looking for a simple way to show

    the status of each
    >project by using colors. Red meaning urgent, green OK

    and yellow some work
    >still needed.
    >
    >Anyone have any suggestions?
    >.
    >


  4. #4
    nbrcrunch
    Guest

    Re: How do I write a formula to color code based on dates provided or.


    Use conditional formatting.


    --
    nbrcrunch

+ 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