Conditional formatting to show date task completed is in/out of target with icons - conditional-formatting

apologies for asking a basic question.
If cell A2 contains the dates a task should be completed by, and cell B2 contains the actual date completed.
Can the icons be used to show a green tick next to the date (in B2) if it is = or < A2 or a Red Cross if it's > than A2?
Many thanks

IMO not exactly a 'basic' Q. One solution, that does not use icon sets but attempts to mimic them, is to place in C1 and copy down to suit:
=IF(AND(A1<>"",B1<A1),CHAR(252),IF(A1<>"",CHAR(251),""))
then clear any existing CF, select ColumnC, choose Windings as font and HOME > Styles - Conditional Formatting, New Rule..., Use a formula to determine which cells to format and Format values where this formula is true::
=C1=CHAR(251)
Format..., select red font OK, OK.

Related

Change cell color when date is older than one year

I made a Userform where i can enter my data like product ID, place,.., in the Column ā€žGā€œ i have the Date(e.g.20.4.2005)(Range is from G2 to G100) - i have bought something. When the typed Date is longer than one year the cellcolor should be turned to red, can somebody help me please?
Using Conditional formating is much better. It work on realtime, right after a cell's value is update. Here's the operation:
Select range G2 to G100
Select tab Home -> Conditional formating -> New rule
"Select rule type" selectbox: Format only cell that contain
Set condition for "Edit the rule Description": Cell Value -> Greater than -> Input the date you wanna compare
Click button Format -> Fill -> Select background colour that you wish
Click OK, OK

Conditional Formatting (If/when)

Ok so I want a row to highlight red when the date in cell C1 is more than the cell in B1, but only if this is a difference of two months or less. I am sorry, I don't know how to embed a dummy spreadsheet. So for example, if B1 (clinic appointment due date) is Sep-17 and C1 (physical checks due date) is Oct-17, I want this row to highlight. If C1 is Dec-17, I don't want the row to highlight because this is more than two months from Sep-17.
Edited based on your new description, using Column A to represent Clinic Appointment Date and Column B to represent Physical Checks Due Date.
Use a rule based on DAYS().
Click on cell A1
Choose New rule from the Conditional Formatting menu.
Choose Use a formula to determine which cells to format
In Format values where this formula is true:, use the below formula:
=DAYS(B1, A1) < 60
Set up the formatting you want to use to highlight the cells. In the image below, I've set the ones that meet your requirements for highlighting to appear in red, and applied it to the first two rows in Column A (A1 and A2):
Here's the sheet with sample data in two rows, showing the conditional formatting working as requested:

Highlight values based on a range of values. Excel

In excel, in a range of cells (say A1 to A100) highlight only values that contain any of the values in a specified range (say A101 to 150). Duplicates among A1 to A100 SHOULD NOT be highlighted. Anybody has a solution?
Give this a try. Select B2:B15893 > go to conditional formatting 'Use a formula to determine which cells to format' > enter formula =AND(COUNTIF($B$2:$B$15893,B2)>1,COUNTIF($B$15895:$B$15924,B2)>0) > Format as Yellow fill > Click OK.
The first logic test in the AND() function tests if the value is a duplicate in range $B$2:$B$15893 and the second test if the value also exists in the range of values at the bottom. If both logic tests are true then the value will be highlighted.
Here is a screenshot of a smaller example. Hope this helps!

How to display a value of a cell using the LARGE formula feature

In Excel using the LARGE function I have listed the top five values in the range of cells C2:C13 into the cells F2,F3,F4,F5,F6. I used the following formulas in the corresponding cells to do so:
Cell F2 I used this =LARGE(C2:C13,1)
Cell F3 I used this =LARGE(C2:C13,2)
Cell F4 I used this =LARGE(C2:C13,3)
Cell F5 I used this =LARGE(C2:C13,4)
Cell F6 I used this =LARGE(C2:C13,5)
Here is a screenshot:
However, what I would like to do is to display the value of the cells to the left of the five greatest values. Below is a screenshot of how I would like it to work if possible:
Please try:
=INDEX(B:B,MATCH(LARGE(C$2:C$13,E2),C:C,0))
in F2 and copy down.
If purely for display purposes you might filter ColumnsB & C an apply a "Top 10..." selection for 5 items.
We could 'cheat' and manage without INDEX in the example provided but, for wider applicability, having chosen the top five values in ColumnF these are then MATCHed to their row numbers in ColumnC and the corresponding row number fed in to the INDEX function to determine the B value.
The following is tested in Google Spreadsheets.
This would be a simple solution:
=MATCH(LARGE($C$2:$C$13,1),$C$2:$C$13)
=MATCH(LARGE($C$2:$C$13,2),$C$2:$C$13)
=MATCH(LARGE($C$2:$C$13,3),$C$2:$C$13)
=MATCH(LARGE($C$2:$C$13,4),$C$2:$C$13)
=MATCH(LARGE($C$2:$C$13,5),$C$2:$C$13)
Another more precise way:
=LOOKUP(LARGE($C$2:$C$13,1),$C$2:$C$13,$B$2:$B$13)
=LOOKUP(LARGE($C$2:$C$13,2),$C$2:$C$13,$B$2:$B$13)
=LOOKUP(LARGE($C$2:$C$13,3),$C$2:$C$13,$B$2:$B$13)
=LOOKUP(LARGE($C$2:$C$13,4),$C$2:$C$13,$B$2:$B$13)
=LOOKUP(LARGE($C$2:$C$13,5),$C$2:$C$13,$B$2:$B$13)

IF Cell A1 = Yes then Fill Red Color in B1

I have a worksheet in Excel-2007
If Cell A1 has a value of 'Yes' in it then I want the Cell B1 to be filled in red color (irrespective of the content in Cell B1).
About conditional formats.
Expand Formulas as formatting criteria, then expand Example 3.
Example workbook is available.
Select B1, HOME > Styles - Conditional Formatting, New Rule...
Use a formula to determine which cells to format
Format values where this formula is true:
=A1="YES"
Format..., select red, OK, OK.