Excel conditional formatting is a really powerful feature when it comes to applying different formats to data that meets certain conditions. It can help you highlight the most important information in your spreadsheets and spot variances of cell values with a quick glance. Continue reading
Comments page 8. Total comments: 318
Hi guys,
I'm making a spreadsheet for a syndicate I will be doing soon and need help.
This is the first table of the page
Name 1 | 1 2 3 4 5 6
Name 2 | 12 11 10 9 8 7
This is the second table on the page
Draw 1 | 1 54 12 6 5 7
Ok, so on the second table what I want to happen is that when the numbers are drawn I need excel to automatically fill the number in on table one so I know that they've been drawn.
Please can someone help, I would be truly grateful.
we have give formula in column M that if column L in -figure than column M should show Amount Due, Same way if Column N have a received date than column M should change as Received
Hi Svetlana, Irina
I am trying to use conditional formatting of cells using the rule definition as : =($CM:$CM="Red"), but couldn't able to achieve it MS Excel 2010, but it works smoothly in Kingsoft Spreadsheets. Any solution for this ?
Thanks in advance to you 'Super Girls'.
Hi Waleed,
In Excel conditional formatting rules, cell references are relative to the top-left most cell in the applied range. That is why, instead of specifying the range in the formula, you should supply the top-left cell only. In your case, select the entire column CM, and create a rule with the formula =$CM1="Red"
Excel will apply the rule to the whole column and adjust the row reference like it does when you copy a formula down a column.
For more information about cell references, please see Relative and absolute cell references in Excel conditional formatting rules.
Dear Developer, Often I use conditional formatting at my Excel spreadsheets, however the condition (color) used to explain the reason of a cell or a range, can differ based on the designer and the user of the product/workbook, in this case I have to first train the user, that why I had put that condition to get particular color, Here it is difficult for one to use the spreadsheet without explanation, is there way; where I can put my text Explaining the reasoning?
Or suggest to add a text field at conditional module to add user thought.so that user can read the reasoning why this condition has been inserted/used
E.g. We all Universally know that RED means Danger, Yellow means be alert or, Green means OK, but it may differ based on the user prospective, if he does not know what the RED stand for, or Green is OK or v/versa
In my case color Blue can stand for RED
Please let me know
Happy New Year 2016
hello, pls am trying to use a colour code for excel i want to use a data in one column to change the row colour based on the input on any other column like i have a 7 in column b and want it to change to a colour red when i input D in any other column
Hello,
Though you can't create a rule for all columns, you can try listing certain columns that the rule will check. E.g. select column A and create a rule with the following formula:
=OR($B1="D",$C1="D",$D1="D",$E1="D",$F1="D",$G1="D")
If any of the listed cells contain "D", it will highlight the cell in column A.
First- I want to thank you for all the great tips. I am creating a workbook that has 6 tabs (goals) - each tab containing the goals for a particular metric for a particular region. Each tab is identical in set up but has different values for the goals. I also have 6 tabs with each regions report card. On those tabs i enter the actual result for a metric and use conditional formatting to look at the value to the goals tab for that particular region. If i create one report card i want to be able to copy it 5 times. My problem is the conditional fomatting will still look at the conditional formatting for the first one i created and look at the 1st goal tab. I want to be able to copy the original worksheet but want a quick way to change the worksheet reference in all conditional formatting formulas for a particular worksheet- can this be done?
Hello Karen,
When you copy the conditional formatting rule, you need to change the worksheet name; please also make sure you use relative references for your rules.
You can find more information about absolute and relative references in this blog post:
https://www.ablebits.com/office-addins-blog/relative-absolute-cell-references-excel-conditional-formatting/
I want to compare one column A of Catalog Numbers containing lot numbers in column B to one column C of Catalog Numbers containing lot numbers in column D and populate the items that match in column E as 0 and the items that don't match in column E as-1 and highlighted in red,
Hello,
If we understand your task correctly and you are trying to compare the lot numbers in column D to lot numbers in column B, then enter the following formula into E1:
=IF($D1=$B1,0,-1)
Copy it down the entire column to get the results for all rows.
Then create a conditional formatting rule with the formula below to highlight those cells in column E that contain "-1":
=$E1=-1
Hi,
I have two rows, the first one with various targets/thresholds and the second onwards with achieved values. While I apply the conditional formatting it gets applied to the entire table. Since the targets are different for each row, I could not do it by just formatting the first row and pasting the format for the rest. There should be a work around which I'm not aware. Please help.
Hello Karthik,
Most likely there is an issue with absolute and relative references in the formula you use for the conditional formatting rule. You can add a dollar sign before the row or column reference to make sure it is not changed. Please see this blog post for a detailed description of using relative and absolute references in your conditional formatting rules:
https://www.ablebits.com/office-addins-blog/relative-absolute-cell-references-excel-conditional-formatting/
Thank you so much for the reply Irina. Your solution helped me a lot of time.
I need help in inserting specific comment based on the value of certain cell. E.g.: If the value of cell A1 is greater than equal to 3 then I would like to generate a comment in B1 stating 'reporting not required', so as A1=4, comment in B1 should read as 'reporting required' and so on for different values in A1. Is this possible in Excel? Appreciate your guidance.
Hello Shiv,
You can add the following formula to cell B1 and copy it down the column:
=IF(ISBLANK($A1),"",IF($A1<=3,"reporting not required",IF($A1=4,"reporting required","new rule")))
Hello,
Whether can we autocapture the formatted text such as (B,U,L) and replace with some html tags.
Can i know how to write it.
Regards,
Navaneeth
Hi,
WHAT FORMULA TO USE TO FILL UP THE CELL,THANKS
SHIPREFT COUNTRY SHIP MODE
JTWA555666 ? ?
JSYS2555333 ? ?
JBKT555999 ? ?
Ship COUNTRY SHIP MODE
JSYS Australia SEA
JTWA TAIWAN AIR
JBKT THAILAND TRUCK
Hello Lisa,
You need to use the VLOOKUP function for your task. Here is the formula you need to enter in the "Country" column:
=VLOOKUP(LEFT(A16,4),Sheet2!A1:C4,2,FALSE)
It looks at the first four characters in cell A16 (your SHIPREFT), compares them to the value in the first column in Sheet2!A1:C4, and returns the corresponding value from the second column in that range.
You can learn more about the VLOOKUP function in this blog post:
https://www.ablebits.com/office-addins-blog/excel-vlookup-tutorial/
Hi, is it possible to create a rule to give a value to a work.
For example: I have a checklist and from a drop down list I can select a number of words, Conformance, Non-conformance and Partial non-conformance, now I would like to automatically have a value assigned to each of these in another column.
i.e. Conformance = 3; Partial non-conformance = 2 and non-conformance = 0.
How would I do this.
Hello Lizl,
You can enter the following formula into the cell where you want to get the value:
=IF(F2="Conformance",3,IF(F2="Non-conformance",0,IF(F2="Partial non-conformance",2,"")))
Here F2 is the cell with the drop-down list.
hi anybody can provide me excel data for practise.
Hello,
You can use our Random Generator add-in to create sets of data for practice:
https://www.ablebits.com/excel-random-generator/index.php
Need to lock conditional formatting but still allow values to be pasted into those formatted cells from other sources.
Problem: I have set up a spreadsheet that highlights cells that need to be populated or left blank. Certain cells that need to be populated are highlighted based on a particular part type (which is chosen from a dropdown menu for the cells located in column AF). Since we are looking over data that can be up to 2000 thousand rows and covering columns A-CL it would take hours to retype all the information to ensure the right columns are populated based on that part type. It is easier to just paste the values in from outside sources. However, it would make it easier to audit the data if the highlighted cells remained highlighted after those values are pasted in.
Question: Is there a way to lock the formatting while at the same time allowing those conditionally formatted cells (that are highlighted) to have values pasted as an overlay from other sources without deleting the format?
Thanks,
Hello Aaron,
Unfortunately you can't keep conditional format using the standard means of Excel. You may be able to do this with the help of VBA, please try posting your question on the VBA branches of the following websites: https://www.excelforum.com/ or https://www.mrexcel.com/
Great Svetlana Cheusheva,
Hope you will be fine.
Today I did my best to solve one of my problems regarding conditional formatting and at last when I read your guidelines and instructions step by step. So these procedures were really easy and were found satisfactory and would like to say special thanks & regards to your efforts and technical support to the needy individuals who are facing problems in MS excel.
Once again thanks
Regards,
Cadet Dani
Hi
I have two documents in word containing employee's names but one document starts people's names like Yusuf Mariam and the other Mariam Yusuf so it's confusing me wheather it's one person's name or two people with different names.Please help me with the format i can use to identify them in excel 2013.
Hi
How do i copy the colour in a formatted cell to a name cell?
Thanks
Is there any way to use conditional formatting to show cells that have been edited? I cannot use Track Changes because I do not want to convert my table to range.
If not conditional formatting, is there any other way to do this?
Hello Shannon,
Conditional formatting can't do this, you need a VBA macro. If you don't need to keep the changes after you close the workbook, you can use the code below:
- Open your Excel file and press Alt+F11 on your keyboard;
- Select the necessary sheet in the list and paste this code:
Private Sub Worksheet_Change(ByVal rnUpdated As Range)
rnUpdated.Interior.Color = CLng("&H00FF00")
End Sub
I WANT TO KNOW THAT HOW CAN I GET THE HIGHLIGHTED CELL FOR TOP 5 PERSON'S NAME ON THE BASE OF ORDER... EX:-
CUSTOMER NAME ORDER QUANTITY
JOHN LARSON 120
FRANCIS MONTGOMERY 126
JENNA SAIZ 67
KELLY PICKETT 98
MARIA HERNANDEZ 111
HUGO LAWS 210
RICHARD BAKER 106
JOEL CANO 130
STEVE TAYLER 36
PLZ.. GIVE A SOLUTION FOR THIS IN A EASILY UNDERSTANDABLE WAY.. THANX IN ADVANCE...
good day
excel 2010,
conditional formatting rules manager
new rule
format only cells that contains
format only cells with
cells value
equal to:4 and 5 and 10 and 17 and 35 etc..in the same line
(not equal to:4
then
equal to 5
equal to 10 in different lines
all those numbers in one line)
then format
fill
and so on
is it possible in excel 2010 or 2013.
thanks
Halevy yosef
Hi, I am trying to create a conditional format the when Cell B2 = or contains a certain word then a particular number goes into cell C2, D2 or E2 depending on what Cell B2 contains.
ie if B2 = cat then C2 = 1, if B2 = dog then C2 = 1 and D2 = 1 etc
Thanks in advance
Hi Jurgen,
With conditional formatting you can only "format" cells, i.e. change their background or font color, add icon sets or color scales, etc.
To put a certain value in a cell depending on another cell's value, you need an IF formula. For example:
Formula for C2: =IF(OR(B2="cat", B2="dog"), 1, "")
Formula for D2: =IF(B2="dog", 1, "")
Hi can you help me with this problem?
I want to separate the amount in an excel 2007
For example:
A1 = 12
I want the answer would be
A2 = 5 (Constant/or Keeps the value Lesser or equal to 5 but not negative)
A3 = the excess amount from the value of A1
Hi Kimoy,
If my understanding of your task is correct, you can simply put 5 (or any other number you want) in A2, and =A1-A2 in A3.
Hello, I am trying to do conditional formatting on a finacial scorecard. I need to do Red, Yellow Green based on the following criteria.
Column B is my target revenue - $30,000 - Every column after that is for a week of revenue and I need to color them based on the following guidelines.
Within 5% - Green
Within 5-10% - Yellow
More then 10% - Red
So if Column D's revenue is $45,000, I need to color it Red. But if column E's revenue is $30,500 it should be green.
I have tried everything and I am sure I am making a silly mistake. Can you please help?
Thanks!
Hey Tina,
I don't know if you're still having this issue, but this may be helpful to other users if you've already figured it out!
Assuming the following:
- The first target revenue is in B1 (if not, simply adjust the formulas used below)
- The first week's revenue is in C1 (same note as above)
You can do the following to accomplish your goal:
(With C1 selected)
We need to make three rules, one for each case. All of the following rules will be added using the following process:
1. Click the "HOME" tab on the menu bar
2. Click "Conditional Formatting"
3. Click "New Rule..."
4. Click "Use a formula to determine which cells to format"
### For red: ###
Assure that C1 is selected!
1. Begin adding a new rule (using the process above)
2. Paste the following formula in the formula text box:
=OR(C1$B1*0.1)
3. Click “Format…” and set the fill color to red
4. Personally I set the font color to white to make it more readable, but this isn’t necessary
5. Click “OK”, you’re done!
Now when the revenue in C1 is outside a 10% margin of the target revenue, the cell will be filled red! (Note that blank cells will also be filled red, this is covered in the section “Catching blank cells”)
### For yellow (very similar to process for red): ###
Assure that C1 is selected!
1. Begin adding a new rule (using the process above)
2. Paste the following formula in the formula text box:
=AND(C1>=$B1-$B1*0.1, C1=($B1-$B1*0.05),C1<=$B1*1.05)
3. Click “Format…” and set the fill color to green
4. Click “OK”, you’re done!
Now when the revenue in C1 is within a 5% margin of the target revenue, the cell will be filled green (be sure to check out the “IMPORTANT” section to make sure this works)!
### Catching blank cells: ###
Assure that C1 is selected!
You can skip the next section if you want blank cells to be filled red (or don’t mind either way)
1. Begin adding a new rule (using the process above)
2. Paste the following formula in the formula text box:
=ISBLANK(C1)
3. Click “OK”, you’re done!
Now blank cells will simply be ignored!
### IMPORTANT!! ###
To assure that the rules act as intended please do the following:
1. Click “Conditional Formatting”
2. Click “Manage Rules…”
3. Make sure that the rules are in the following order (distinguishable by the fill color):
Blank
Green
Yellow
Red
NOTE: Rules can be moved up or down using the arrow buttons to the right of "Delete Rule"
4. Make sure that for each rule the “Stop If True” box is checked (far right column)
This assures that only one rule will be applied to any given cell
### Finishing up: ###
Now that we have all the rules made for C1, we want to be able to apply the same rules to other cells!
The process for copying conditional formatting is included in the main article, but the process is summarized below:
1. Select C1
2. Click “Formula Painter” under the “HOME” tab
3. Drag from C1 to the end of the range of cells you wish to copy the formatting to (e.g. from C1 to L1 or from C1 to C10 or from C1 to L10)
That’s it! Please let me know if you (or anyone else reading this) experience any problems!
I have three rows of numbers with the highest number highlighted in each row. Can i highlight the lowest number of only the numbers that are already highlighted?
Hello,
Need some help with a formating rule. I have several times in one colum example:
4:17:49pm
2:05:03pm
11:15:04am
9:00:49am
And I want to do a color rule to highlited red if the time difference is more that 2 hours apart. How do I do this? Someone please help me out.
Thank you a bunches
Alex
Hello Alex,
Could you please specify what time values you are trying to compare?
Sorry Ms. Cheusheva,
I just came across your comment to Stuart above. I will check out that link to see what I can do.
Cheers,
George
Ms. Cheusheva,
Thank you for an informative explanation on conditional formatting. I do have a question though with my Excel 2007. I have notice that visually if I use the conditional formatting to change the colour of the text in the cell to a colour like red, I can see it in the spreadsheet, but I can’t run any macros or functions against it (like countif = red)? After some checking to see where the problem is, I notice that the text in the cell that even though visually to the eye it is red it has the default code of black when I check the font format? Is this a bug or something that I am missing?
Cheers,
George
I found your link to Stuart. I will read through that and see.
Cheers,
George
Its worth a shot... but I am trying to run an audit on a a spread sheet, and am using the Conditional Formatting. I have been trying to high light cells in a Column that is used for Hours submitted on a time sheet. Our company policy is to round to the nearest 15 Minute increment. So I would like to highlight any cell that is not rounded to the nearest 15 minute increment. I read several places how excel divides an hour up in percentages, but cannot find a formula to highlight the field without Rounding it. I am new to the formulas so I need assistance, or, even if you can point me in the right direction...?
Hey Amy,
Assuming the hours submitted are in decimal form (e.g. 6 or 8.0 or 7.75) you can use the following to accomplish this for a single cell (then use the process outlined in the main article to copy the rule to other cells):
1. Click the "HOME" tab on the menu bar
2. Click "Conditional Formatting"
3. Click "Add Rule..."
4. Click "Use a formula to determine which cells to format"
5. In the formula text box paste the following formula and replace "##" with the cell you want to apply the rule to
=NOT(MOD(##,0.25)=0)
6. Click "Format" and select a fill color (I picked yellow)
7. Click "OK" for the format and then again for the rule
8. Done!
Now for any cell that the rule is applied to, if the hours recorded aren't rounded (e.g. 8.2) the cell will be highlighted!
I should amend part my last sentence to say "if the hours aren't rounded to the nearest 15 minute increment"
Hi Svetlana,
How do I get a sum for shaded cells of varying colors (and just a shaded cell total not the actual value in it)
Thanks.
Hi Stuart,
You can do this using a custom user-defined function, like the one described in the following post:
https://www.ablebits.com/office-addins-blog/count-sum-by-color-excel/
I have a spreadsheet several hundred lines of products with the prices from 5 vendors in column . I want to auto-highlight the column that contains the lowest vendor price for each product (that is not zero). How could I get this to work with conditional formatting?
Thanks for all your insight, very helpful. I have a simple budget spreadsheet and have set up a conditional formatting rule that works well. What happens is column B is my target monthly budget. Columns C through M are what I have spent each month. When I go over the number in column B the cell highlights.
Rule Format Applies to
Cell Value > $B$2 AaBbCc =$C$2:$M$2
Works great, what is bugging me is I can’t figure out how to copy and paste to the other rows and change the rule for the “cell value”. It keeps $B$2 but does change the “applies to” cells. I know I could have done each row separately in the time I have spent on this but like I said it is bugging me. Thanks in advance ;}
Hello Dave,
You just need to change the absolute row reference in your formula to relative, i.e. remove the dollar sign before the row number: =$B2
You can find a detailed description of the differences between absolute and relative references in this post:
https://www.ablebits.com/office-addins-blog/relative-absolute-cell-references-excel-conditional-formatting/
Hi svetlana
i have 5 columns with 5 different subjects.I need to show the student who has below 15 marks in all subjects.
example
St name col1 col2 col3 col4 col5
xxxx 10 20 16 9 18
yyyy 18 22 17 19 10
zzzz 20 21 12 19 19
AAAA 25 21 18 19 19
BBBB 26 25 19 23 20
i need to display like this (those who having below 15)
St name col1 col2 col3 col4 col5
xxxx 10 20 16 9 18
yyyy 18 22 17 19 10
zzzz 20 21 12 19 19
help me....
thanks in advance.
hi svetlana
i have 100 rows with different values,some of values are highlighted with conditional formating, i need to show highlighted values only, unhighlighted values are to be in hiding.
Hi,
I am looking for some pointers for the problem I have. There are three Columns which has values like
Column_1 Column_2 Column_3 Result
R239 G232 B110 RGB(239,232,110)
G210 R134 B156 RGB(134,210,156)
And the output should be what you see in Result column. Basically R, G and B values are scattered in the first three columns, but I need them in such a way that it looks like what is displayed in the Result column.
I would really appreciate if someone can look into this. Thank you for looking into it.
SK
Hi Svetlana
Hope you can help me...
I'm using conditional formatting for two columns (ctr and ranking), but need an "if" statement to do the following...
ctr => 20% + ranking =<3 = green
ctr 3 = red
ctr =>8% + ranking between 4-6 = green
ctr 3% + ranking between 7-10 = green
ctr <3% + ranking between 7-10 = red
Can you please help??
I am on skype if you can inbox me please
Thanks
Chantel
the colour of the box which i edited should change the colour automatically to know me which i was edited is there any settings please help me
TIA
Hi Bunny,
Sorry, it is not possible to do this using conditional formatting. Most likely a special VBA macro is needed.
In my work book i am using 3 columns, first column contains value and second column contains dates of completion fist process and third column contains the date of completion of second operation. how can i use formula to filter what is completed and balance to complete (i meant Backlog) in excel 2013.Please suggest a formula .
thanks
Hi Svetlana,
How do I highlight a cell that has a variance of 20% or more when comparing to another cell
Thanks
Hi Stuart,
You can create a conditional formatting rule with the percentage change formula like this:
=OR((B2-A2)/A2<-20%, (B2-A2)/A2>20%)
Where column B contains new values and column A - old values.
* Col-A = Col-B: Yes
* Col-A Col-B: More
I don't know why it did not post all 3 rules in here.
(Question 1 above (#43) missing info)
set 3 rules
* Col-A Col-B: More
Example for 2 rules: with "Yes" and "Less/More"
=IF(A1=B1, "YES", "LESS/MORE")
How can I break it to "Yes", "Less", "More"?
Thanks,
Son
Hi Svetlana,
I have 2 questions.
1. I know how to use IF rule with 2 conditions for YES/NO but I don't know how to set a rule for 3 conditions.
* Col-A Col-B: More
Example: with "Yes" and "Less/More"
=IF(A1=B1, "YES", "LESS/MORE")
How can I break it to "Yes", "Less", "More"?
2. Can I set multiple "Conditional Formatting" rule in one cell. Example,
Col-A(number) Col-B(number) Col-C(Y/L/M)
0 0 Y
1 2 L
4 3 M
I can set Condition Formatting for Col-C with "Equal" to "Y" or "M" or "L" with different colors
How can I set multiple Conditional Formatting rules for Cell in Col-A
* A1 "Euqal to" B1: A1 = Green
* A1 "Less than" B1: A1 = Yellow
* A1 "Greater than" B1: A1 = Red
Thank you very much for your help.
Son
Hi Svetlana,
I have numbers in a row and i would like to have them summarized in a cell if something in the row has been deleted. For example:
a1-20
b1-50
c1-30
and i want if a1=0, b1=0, c1=50, then in d1 to have a1+b1 and c1=50
Thank you,
Zoya
In a large spreadsheet I would like to apply conditional formatting to any cell that has an absolute value greater than or equal to 5,000,000. I'm having trouble developing that formula and would appreciate assistance if anyone is familiar with how to do this.
Thank you - Tom
Hello, I hope someone can help me with my problem. I have about 7 different sets of word banks. If a cell contains a word for lets sat word bank 1 I would like that sell to highlight yellow. If a cell contains a word for word bank 2 I would like that cell to highlight red, and so own. Is there a way to do with without making individual conditions for each word?
Secondly, is it even possible to have a cell highlight any color if one column has three yellow highlighted cells in it? This is based off of my first problem.
Thank you. I hope I was clear enough.
I have three columns of data with 100 rows each and I want to check if the sum of the row in column A + the row in Column B = the value in the same row of Column C. If it doesn't then I want to RED highlight the row in Column C. For example: A(1)+B(1)?=C(1), A(2)+B(2)?=C(2), etc.
Thanks,
Dave
Hi,Svetlana
I HAVE 100 ROWS WITH ALPHANUMERIC.LIKE FOLLOWING TABLE
11AS001
12FB005
12KA003
12C40002
12G3005
12je001
12bp005
124j003
129j0002
122q005
from these table i need to return a value based on the character.like that i have more than 10 values
ex..
if cell contains
as------ A
ka------B
g3---C
c4---D
fb---E
4j---F
je---G
bp---H
9J---I
2q---J
I want to return a value like this
Col A ColB
11AS001--- A
12FB005---- E
..
Please help me.
How can you edit multiple Conditional Format Rules at the same time?
I have a row with 36 columns, each with a cell containing 7 conditional formatting rules linking the cell to conditions on cells in a corresponding row on another spread sheet.
I need the next row to have the same conditional formatting, but referencing the cells in the next row on the other spread sheet. Is there some way to hi-light all conditional format rules on all 36 columns and do a search/replace on all of the formulas simultaneously, or is editing them one-by-one my only option?
how to Automatically change the fill color in a row based on 3(m,n,o) columns current month
Svetlana,
I want cells in a column to become highlighted if the date listed in a cell is in the past. I tried:
=$A2<TODAY()
But this doesn't seem to be highlighting any cells with past dates. Any idea how I can set this up? If the first cell with a date is B4, should the formula go into B3?
Thanks.
Hi Peter,
You should modify the formula for your first cell with a date, like this:
=$B4
Suppose you have two Excel Sheets as follows and it’s more than 1000 rows and you cannot do manually:
Sheet 1 Available List:
And Then you have Sheet 2, Client List:
Now The Task:
Your program, excel or whatever app you make shall be in the way that it gets John as input in the app, which has the below requirements:
He’s budget is 150k- 165K and he looks for 2Br Apartment in Greens Area with Furniture
And Shall display outputs as:
Greens
Tanaro
2
1200
95,000
2500000
Mid
Yes
Golf
As everything Match his requirement.