How to change the row color based on a cell's value in Excel
Learn how to quickly change the color of the entire row based on a single cell's value in your Excel worksheets. Tips and formula examples for number and text values.
Last week we discussed how to change the background color of a cell based on its value. In this article you will learn how to highlight entire rows in Excel 2016, 2013 and 2010 based on a value of one cell, and also find a few tips and formula examples that will work with numerical and text cell values.
How to change a row color based on a number in a single cell
Say, you have a table of your company orders like this:
You may want to shade the rows in different colors based on the cell value in the Qty. column to see the most important orders at a glance. This can be easily done using Excel Conditional Formatting.
- Start with selecting the cells the background color of which you want to change.
- Create a new formatting rule by clicking Conditional Formatting > New Rule… on the Home tab.
- In the "New Formatting Rule" dialog window that opens, choose the option "Use a formula to determine which cells to format" and enter the following formula in the "Format values where this formula is true" field to highlight orders with Qty. larger than 4:
=$C2>4
And naturally, you can use the less than (<) and equal to (=) operators to find and highlight rows that have Qty. smaller than 4 or equal to 4:
=$C2<4
=$C2=4
Also, pay attention to the dollar sign $ before the cell's address - it is needed to keep the column letter the same when the formula gets copied across the row. Actually, it is what does the trick and applies formatting to the whole row based on a value in a given cell.
- Click the "Format…" button and switch to Fill tab to choose the background color. If the default colors do not suffice, click the "More Colors…" button to pick the one to your liking, and then click OK twice.
You can also use any other formatting options, such as the font color or cells border on the other tabs of the Format Cells dialog.
- The preview of your formatting rule will look similar to this:
- If this is how you wanted it and you are happy with the color, click OK to see your new formatting in effect.
Now, if the value in the Qty. column is greater than 4, the entire rows in your Excel table will turn blue.
As you can see, changing the row's color based on a number in a single cell is pretty easy in Excel. Further on, you will find more formula examples and a couple of tips for more complex scenarios.
How to apply several rules with the priority you need
In the previous example, you may want to highlight the rows with different values in the Qty. column in different colors. For example, you can add a rule to shade the rows with quantity 10 or greater. In this case, use this formula:
=$C2>9
After your second formatting rule is created, set the rules priority so that both of your rules will work.
- On the Home tab, in the Styles group, click Conditional Formatting > Manage Rules… .
- Choose "This worksheet" in the "Show formatting rules for" field. If you want to manage the rules that apply to your current selection only, choose "Current Selection".
- Select the formatting rule you want to be applied first and move it to the top of the list using the arrows. The result should resemble this:
Click the OK button and the corresponding rows will immediately change their background color based on the cell values that you specified in both formulas.
How to change a row color based on a text value in a cell
In our sample table, to make follow-up on orders easier, you can shade the rows based on the values in the Delivery column, so that:
- If an order is "Due in X Days", the background color of such rows will turn orange;
- If an item is "Delivered", the entire row will be colored in green;
- If an order is "Past Due", the row will turn red.
Naturally, the row color will change if the order status gets updated.
While the formula from our first example could work for "Delivered" and "Past Due"(=$E2="Delivered"
and =$E2="Past Due"
), the task sounds a bit trickier for "Due in…" orders. As you see, different orders are due in 1, 3, 5 or more days and the above formula won't work because it is purposed for exact match.
In this case, you'd better use the SEARCH function that works for the partial match as well:
=SEARCH("Due in", $E2)>0
In the formula, E2 is the address of the cell that you want to base your formatting on, the dollar sign ($) is used to lock the column coordinate, and >0 means that the formatting will be applied if the specified text ("Due in" in our case) is found in any position in the cell.
Create three such rules following the steps from the first example, and you will have the below table, as the result:
Highlight row if cell starts with specific text
Using >0 in the above formula means that the row will be colored no matter where the specified text is located in the key cell. For example, the Delivery column (F) may contain the text "Urgent, Due in 6 Hours", and this row will be colored as well.
To change the row color when the key cell starts with a particular value, use =1 in the formula, e.g.:
=SEARCH("Due in", $E2)=1
in this case, the row will only be highlighted if the specified text is found in the first position in the cell.
For this conditional formatting rule to work correctly, make sure there are no leading spaces in the key column, otherwise you might rack your brain trying to figure out why the formula does not work :) You can use this free tool to find and remove leading and trailing spaces in your worksheets - Trim Spaces add-in for Excel.
How to change a cell's color based on a value of another cell
In fact, this is simply a variation of changing the background color of a row case. But instead of the whole table, you select a column or a range where you want to change the cells color and use the formulas described above.
For example, we could create three such rules to shade only the cells in the "Order number" column based on another cell value (values in the Delivery column).
How to change row's color based on several conditions
If you want to shade the rows in the same color based on several values, then instead of creating several formatting rules you can use the OR or AND functions to set several conditions.
For example, we can color the orders due in 1 and 3 days in the reddish color, and those that are due in 5 and 7 days in the yellow color. The formulas are as follow:
=OR($F2="Due in 1 Days", $F2="Due in 3 Days")
=OR($F2="Due in 5 Days", $F2="Due in 7 Days")
And you can use the AND function, say, to change the background color of rows with Qty. equal to or greater than 5 and equal to or less than 10:
=AND($D2>=5, $D2<=10)
Naturally, you are not limited to using only 2 conditions in such formulas, you are free to use as many as you need. For example:
=OR($F2="Due in 1 Days", $F2="Due in 3 Days", $F2="Due in 5 Days")
These are only a few of many possible ways to zebra stripe your Excel worksheets based on a cell's value that will respond to change of data in that cell. If you need something different for your data set, drop us a comment and we will try to figure this out.
490 comments to "How to change the row color based on a cell's value in Excel"
I have a table in excel with data. I want to apply conditional formatting to it as soon as any data in the table is changed.
Please suggest a way
What if, i have several values but i use one column to sort of group, then i want all the rows with the same "anchor" value to have same color format, is that possible? Example:
box item comments
1 peppers 12345
1 potatoes 132465
3 nails 32164
5 napkins 231354
1 tomatoes 1321
3 tape 1231
and lets say i want all the rows belonging to different box # to have the same color, i guess i could do it one by one but if we are talking of dozens of boxes per say, could there be a more automated way to do this instead of doing one condition format for each?
tank you very much
Hi,
If I enter completed in "I" column, the entire column should need to change? What i need to do?
Just to add to the above, the formulae IF(A2"",IF(B2"",B2,NOW()),"") seem to accomplish, but my excel sheet refreshes every 1 minute, and the moment it refreshes, the time stamp changes to the local computer time (which is current and not the time when the signal came actually).
I even tried my own like =IF(F2="Buy",IF(F2="Sell",NOW(),"")), getting the time stamp, again when the excel refreshes, the time stamp changes to the current time. For e.g. if Buy or Sell came at say 10:15 hrs, after refreshing (let us say 2 minute refresh interval), the time reflected is 10:17 hrs.
I only hope I have clearly stated my requirement.
Cheers
GK
Greetings,
Quite impressed with your responses especially the frequency of your responses, never seen any one taking so much time, which is much appreciated. Namaste !
I have a stock trading work sheet, and there are two things I am trying to accomplish and stuggling a lot :
(1) In my trading sheet, I have Buy and Sell in a certain column which is based on certain conditions (strategy). So these Buys and Sells appear whenever the conditions are met, in Real Time (Trading sheet takes data from the internet and continues to update every 1 minute, so there are many Buys and Sells spawning from time to time). What I am looking for is the exact time stamp (data not so required as I know the sheet is being updated today). Strangely upon scouring the net, every body talks about the same formulae viz. IF(A2"",IF(B2"",B2,NOW()),"") and this does'nt serve my purpose at all. If this is all confusing, let me give a clear example here :
Columns A-E has data like High, Low, Close, Open etc etc
Column F has a signal : Buy or Sell
So all I want is some column after Column F which updates the time as and when a signal appears in the Column F. The reason is I want to see which are the new signals that appeared as I am handling 200 rows of scrips.
OR
(2) Can Column F which contains the signal, Buy or Sell be colored in such a manner it accomplishes the following :
(a) New signal BUY as and when it appears should carry a different color, let us say DARK GREEN
(b) Likewise New Signal SELL as and when it appears should carry a different color, let us say DARK RED
(c) All signals after a time decay, say 1 minute (which if configurable would be awesome), should change color. So in the case of Buy (Dark Green), color can change to Light Green and in case of Sell (Dark Red), color can change to say Orange
Would really appreciate if you can guide/assist me in accomplishing the above.
Warm Regards
GK
how to use formula to if possible?
if left side of / is greater than right side change color of the text
1200/1000 all red text
900/1000 all black text
I'm trying to do the following:
Conditional Format (Cell Background Color in different shades from red to green) a row when it contains a date based on a specific process in the first row, i.e. first communication, presentation, first meeting, second communication, second meeting, commitment.
The excel would look sth like:
Row 1: first communication, presentation, first meeting, second communication, second meeting
Row 2: 9/1, 10/1, 15/1....
Any help as to how I could set that up would be greatly appreciated
Respected Sir,
My problem is that, i want to count Conditional Formatted (Cell Background Color) Cell count..
so plz help me anyone to count colored cell....
Thanks in Advance.........
can i exclude cells in the row from the conditional formatting?
so if column B has a 1 it changes row to green, but i want to exclude column K, or M, so they keep their existing color...
From the below example i need to mark highlight above 10 Days rows using conditional formatting. Can anybody suggest me which formula I can use here.
Days: 12, Hours: 13, Minutes: 51, Seconds: 43
Days: 11, Hours: 16, Minutes: 21, Seconds: 46
Days: 11, Hours: 16, Minutes: 21, Seconds: 46
Days: 11, Hours: 16, Minutes: 21, Seconds: 45
Days: 11, Hours: 16, Minutes: 21, Seconds: 46
Days: 42, Hours: 14, Minutes: 51, Seconds: 37
Days: 6, Hours: 17, Minutes: 21, Seconds: 46
Days: 33, Hours: 17, Minutes: 51, Seconds: 45
Days: 33, Hours: 17, Minutes: 51, Seconds: 45
Is there a way to have the cells highlight every time the number changes? For example I have a table that has item codes and in order to make it clearer when changing to a different item code it changes color. So if I have 3 rows with the Item code 608 then 5 rows of item code 609 then 2 rows of item 610 and so on, it will highlight the 608 items and the 610 items skipping the 609 items.
608-highlighted
609- not
610- highlighted
611- not
612- highlighted
and so forth
For example, I have a column starting at A2 where I have my numbers (601,602... 900) and then all my data to the right. I want all even numbers highlighted (the whole row) and the odd numbers highlighted a different color.
Go to the drop-down list for conditional formatting on the home tab and select "new rule".
Select Use Formula to determine which cells to format
Add the following formula
=ISEVEN($A2)
It is important not to have the second $ next to the numbers.
Next to the Preview select "format"
Select the Fill tab and select the color you want
Select ok.
Click on the drop down list from conditional formatting and select manage rules
In the "applies to" section of the rule you just created, select the "data range" icon on the right and click and drag from the top corner to bottom opposing corner of the data you want highlighted.
You can create a second rule with "=isodd($A2)" if you want to choose the other color.
Hope this helps.
Hi,
I am trying to set up a formula that for when a cell changes text and matches another cell, it turns green. For example, if B2 and E2 both say 'strip', then E2 will turn green. But then if cell B2 then changes to say 'paint', and so does F2, then F2 will turn green. However, I still need to keep E2 green as it is a step by step process which tracks the progress of a part, so every step needs to be a green colour once completed.
Cell B2 will automatically be updated from another workbook.
If there is a way to do this without having to fill the cells in manually then please someone let me know as I have around 500 columns to fill in.
Thanks :)
how can i highlight entire row based on one cell,
Ex: Column c Named "Raheem" and it become red and if i change the name , it want to change another colour
Raheem:
I think you'll find the answer to your question and also learn more about conditional formatting in this article.
https://www.ablebits.com/office-addins-blog/2013/10/29/excel-change-row-background-color/
Hi Svetlana,
I am trying to apply conditional formatting, for example, if anyone fill red colour in cell A1 then red colour should automatically fill in cell B1.
can you please help me on this
I want to have the font colour change when I change the cell colour.
If I make the cell red I would like the font to change to white. Is there any way to do a conditional format for this?
Terri:
There is the option to modify font color in the same window where you modify fill color. After you click the Format button in the Conditional window, then Click the "Font" tab and you will see the options. The fill and font will both change colors when the conditions occur that you have indicated in the Conditional Format dialogue.
Thank you so much! This was incredibly helpful and easy to follow! Bookmarking it for future reference :)
How do I use this formula to highlight the entire row based on just a date entered into a cell in a particular column?
is there a way i can format rows from the value that is in one cell without giving every single row a formula?
Levi:
Yes, you can do this. Here's how.
If you want to highlight rows based on the value in say the cells A2:G2 and column B will always hold the data we want to use to control the formatting of each row.
First, highlight all the cells you want to be affected by this formatting rule. Let's say A2:G5.
Second, click Conditional Formatting
Third, click New Rule
Fourth, in the New Formatting Rule window, click Use a Formula to Determine Which Cells to Format
Fifth, in the rule box, enter a formula that refers to the active cell in the selection. Let's say we selected A2:G5, and cell B2 is the active cell. So, in the formula, we'll refer to cell B2, because it's in the active row. =$B2>70 Remember, column B holds the data we use to determine formatting for the row.
We need to use an absolute reference to column B ($B), to ensure that the conditional formatting in all columns refers to the value in column B.
If we use a relative reference (B), the formula will be adjusted in each column, and won't work properly. Each cell would refer to the cell to its right, instead of referring to the cell in column B.
Sixth, click the Format button.
Seventh, in the Format Cells dialog box, select the formatting options that you want.
Lastly, click OK to close the Format Cells dialog box.
That should have formatted the list of cells A2:G5.
Test it to see if it works by entering values greater than 70 in cells A2:G2.
You can extend the row highlighting by selecting the last formatted row and grabbing the little box at the bottom right of the cell and copying down.
I have a cell that i need to change yellow if it is within 1% of another cell. I need that cell to turn green if it is at or above the percentage goal and red if it is 2% or lower than the goal. The goal is not always 100%. So if the goal was 90%, and the other cell ends up being 89% it should be yellow.
Hi,
Was wondering if anyone could help.
I'm trying to find a formula that will highlight a cell if that cell = 227 and the cell below = 867 or 965.
Thanks in advance,
Carl
This is amazing. Thank you!
Hello,
I would like to have individual cells in one column highlighted if they are equal to or greater than a percentage of the value of the cell in the previous column.
Is this possible to do?
Thanks in advance,
Paul.
I have 2 conditions in one column yes or no
Yes have pink color and no have yellow so which is the formula is used here to do so i wanna to do samething in other sheet
Automatically it converts when I write yes or no
Hi,
I want my spreadsheet to change the color of each row only when an item number I have in Row B changes to a new Item number. These item numbers are not equally spaced and have no consistent scale or system to them.
The only identifying factor is that the number changes to a different number, sometimes 5 rows apart other time 30 rows apart. The spreadsheet is over 70,000 rows. Solutions?
Hi everybody,
I need help please, i want to apply rules in my excel sheet,when i type specific word (Friday) row and column colour should be change, please help me resolve this.
I want to color rows whennI type in yes or no of a certin Item in our inventory has been cycle cou ted... please help
please try to help me i have workbook in that workbook i have two sheet (Data Entry Form) & Monthly report per day in calms and in rows name time i want to change cell background color in monthly report. Just i put in data entry form name of site and in monthly sheet automatically change cell color by site.
i am working excel workbook.
Hello,
For me to understand the problem better, please send me a small sample workbook with your source data and the result you expect to get to support@ablebits.com. Please don't worry if you have confidential information there, we never disclose the data we get from our customers and delete it as soon as the problem is resolved.
Please also don't forget to include the link to this comment into your email.
I'll look into your task and try to help.
How to "Conditional format all cells by using a four-color scale".
Hello, Kobus,
I'm afraid it's impossible to use four-color scale in conditional formatting. But perhaps VBA macros can help you. You may try to find the solution in VBA sections on mrexcel.com or excelforum.com.
Sorry we can't assist you better.
Hi, I want to ask you question and need your help
want formula to do the following: if cell G1=text and date in the selected cell J1 is before 60 days then high light the row or selected cell
and if cell G1=text2 and date in the selected cell J1 is before 90 days then high light the row or selected cell
and if Cell G1=anyothertext please do nothing
What formula can I use to change the font color of a row to red if a cell in that row is a date prior to today? And how would I repeat that for all subsequent rows?
Thanks!
Hi,
Why i follow you but it highlighted all of selection area, not only rows which contain the cell has specific words i defined?
hi,
in may excel sheet lots of column and row, in last column header is status that contain DIS, RFD, RFI, 2, 3, 4, NP etc. If i put up DIS IN THAT COLUMN TOTAL COLOUR OF RO changes to green. how i do these
This post was very helpful, but still need some additional assistance:
I have a sheet used for inventory for deployed computer hardware. Not only is this data stored in the sheet but parts of it are also stored in our ERP system. And accounting needs to know when a computer is deployed so they can move the cost from IT to the deployed department. So I created columns for ERP and Accounting Notified that when those tasks are completed I simply put a Y in the cell. If there is a Y in either cell, highlight the row orange, and if there is a Y in both cells highlight the row green. This works fine when working with 1 row, but I need to replicate this down the entire sheet. What is the best way to accomplish this?
Got it figured out. Had my conditional formula looking at a specific cell instead of a column.
Hi Brian, I am having a similar problem to the one you described here in that I would have to replicate the formula for each row individually for it to be highlighted if a cell in the row contained "Completed". Can I ask you how you rectified your problem? Thanks
thanks for this lesson ... really appreciated
Sorry, should be this..
What I’m trying to do is basically have 4 rules determine what colour to highlight an entire row based on what percentage it is in a cell. Not sure if they can be combined or not.
If Column B percentage is 0 then highlight blue
If Column B percentage is >15 then highlight yellow
If Column B percentage is >50 then leave white
Hello first of all, very grateful for the article and your help.
What I’m trying to do is basically have 4 rules determine what colour to highlight an entire row based on what percentage it is in a cell. Not sure if they can be combined or not.
If Column B percentage is 0 then highlight blue
If Column B percentage is >15 then highlight yellow
If Column B percentage is >50 then leave white
Your first example doesn't work. In fact, the picture that shows the result doesn't even show what you say it does.
Hi Stephen,
The example works, but a wrong picture somehow showed up on the blog. Thank you for pointing that out, fixed!
Hi there,
How do I change a colour on a row of columns when a particular column is typed into eg in that column I will type YES and the entire column line turns green?
Hi, Doreen,
let's suppose you have a table A1:D7, you type "yes" into C2 and the entire row A2:D2 turns green.
For that you need to create a formatting rule saying:
=$C2="yes"
and make sure the rule is applied to
=$A$2:$D$7
Please read the first point of the article above in order to see how to choose a colour for the conditional formatting rules.
Hope this helps!
Hi Sevtlana,
Could I please request your help.
I am having a trouble in colouring a cell , which is dependent on the value of other cell in different TAB but same worksheet. for example , if source cell has value between 90 & 100 , destination cell should reflect green colour..
Can you help.
Hi, Summit,
to solve the task you need to use "AND" function in the formatting rule. If you mean that you work within one workbook, where the source cells are in the TAB2, column A, and the destination cells are in the TAB1, column A, the formula will look like this:
=AND('TAB2'!$A1>90,'TAB2'!$A1<100)
If you mean, that you work with different workbooks – change 'TAB' into '[Tab.xlsx]SHEETNAME' accordingly.
To understand how the sheet references work, feel free to check this article out.
Hello Sevtlana,
I saved an excel sheet from the "searchmyfiles" app. It's an inquiry for duplicate file names on all my drives. I've sorted them by duplication number which range from 1 to over 1000 files that have duplicates. I have some files that have been duplicated up to 10 times. I'd like to highlight every other duplication number (NOT every other row). Can you help me with that, please?
Hello, Mary,
here you can find an easy tutorial that may be of great help.
I have a financial sheet that I use, once the check has cleared the bank I highlight the cell. I am trying to figure out the format that will change the total in the summed cell when I highlight the payees cell but not change the value (amount) within the cell (once highlighted the value becomes zero, but leaves the amount in the cell), reflecting the amount that was paid, but affecting the end state balance.
Old formula is
=sumifs('m.16-1'
I want fill colour in cell by formula, but I have different sheet of issue from and final report sheet separator in another sheet but I one worksheet
And I have all ready one formula in.final report sheet.
So help me how I can make formula
1.Customer 2.Description 3.Status 4.Del Date 5.Billing date 6.Order Val 7.Comments
Hi
Points 1-7 are my coloumns. I want to apply a rule whereby the status on each specific row will change the colour of more than one cell in that row (2,3,4,5,6), like for instance, if job complete the row should turn green.
However my limitation at the moment is that I can only apply this one row at a time whereas I need a rule that can apply to the specified rows...
I hope that I am making sense.
Hi, I am formatting our worksheet and each values must change color depending on it, so I was wondering how to apply the conditional formatting on over 2000 rows.
Hi,
I am trying to make a planning with excel.
I have set up the following conditional formatting:
=AND($D$3>=$B$4;$D$3=$B$4;$E$3<=$C$4)
I don't want to set up this rule for every single cell so I will have 200 rules eventually.
Is there a way to dynamically applie this one rule to all the necessary cells? like doing with the value of some cells if you want to quickly fill those cells. Then you can just fill in 2 values and pull the values across the necessary cells and Excel will automatically fill in the right values.
Thank you Svetlana and everyone. Your Q&A have helped me in learning more about Excel.
Hi, I hope you can assist. I am needing something like this done in a VBA macro.
I am using both 2007 and 2010 version of MS Office Excel.
Problem: Store POS does not have Low Inventory Report built in (free/cheap version). We download a CSV file with 3 fields: Item, Category and Balance. We then manually add 3 more fields: Previous Balance, Quantity Received and Quantity Sold. The CSV is then filtered to copy only items we still carry to a new workbook (old items can not deleted from the POS Inventory). A macro is used to separate items based on category name to different worksheets.
We have over 100 different categories, each category has a different number of items. Item Name (Column A) cell is colored based on Quantity on Hand and Number Sold. If Quantity on hand = 0, cell is Red, If Quantity on hand = 1 or 2, cell is colored yellow; if Sold = 1 - 3 then cell is colored Blue and if Sold is higher than 3 then the cell is Green. If The Quantity is 0-2 AND the Sold is 1 or higher, then the text will be bold and colored the Sold colors (Blue or Green) while the cell is still filled with the On Hand Colors (Red or Yellow).
Doing the conditional formatting manually for every worksheet takes me a couple hours. Is it possible to use a VBA macro to do all worksheets for all conditioning? If you can show the script to get me started, I would appreciate it. I can do a script for a single worksheet when the range (number of rows) is known and also for a single condition. If possible, 1 macro to do all worksheets (total number of worksheets can change) and more than one condition.
Hi I need to use this example but it wont work for me. Im using it to look at the status of work so i have 4 statuses complete, active, Not Confirmed and Cancelled. I want to change each row colour when i change the status of the job. I have tried your example as per above highlighting all my area so its highlighted from A6:P31 then created a new rule with the formula =SEARCH("Active",$F$6)=0 it works but changes every row on the sheet. I want it to just change that one row? what am i doing wrong? Row F wil always be my status bar and i have about 100 rows of work im looking at?
Hope you can help.
Elaine
Hello - I'm trying to use conditional formatting to check row by row within a range (A:G) for any blank cells. If there is a blank cell in the range I want to highlight the cell for that specific row in column A red. I want formula / conditional formatting to be able to do this for each row through the entire spreadsheet.
Example for Row 2: If cell C2 is blank within range A2:G2, I want to highlight cell A2 red.
Any help would be greatly appreciated.
Thanks, SEARCH helped solve my problem statement.
Hi, I need help with excel.
I have database of my daily work tasks which includes dates in one column and in the other columns I have other datas that are mostly in text. Now I need an excel code/function that can provide a "summary of tasks" that I did by each date listed and a respective count of how many tasks were completed on that specific dates. For example if only 10-december, I have 4 entries of work and on 11th-december, I had 14 then the excel should count and prepare a summary of my work like this
Summary of Work
Dates Tasks Completed
10-december 4
11-december 14
If somebody can prepare a format or a code and post it, I would really appreciate it. Please note, the excel code should also reflect any changes I make on the dates or counts. For example, if I find that the date was incorrect and I change it to 12-december, the summary should reflect that right away.
thank you.
I want colored two different values with two different colors which is in one cell. How I can?
I have a rather large worksheet with workorders that need to be completed. For each workorder a specific skillcode is recquired. On a daily basis, I have a set amount of available hours for production. I've added a column that adds the amount of workorders that can be completed on a day until I've hit the maximum for that day. In the following cell it starts to calculate again.
Example: I have 60 hours available, and in column D I have the amount of hours per workorder. Column E has an if statement that says when the hours in D have hit 60 hours, start the calculation from the start: E19 = 59.2 hours -> E20= 6 (the required time for this new workorder). I want to format the worksheet in such a way that each time it starts the calculation again, a different color is used (E2:E19 = blue, then E20:26 = red and so on). Can you perhaps help me out on this?
Oh my goodness! Do you know how long I was trying to figure this out??? Thank you so much... The help function in Excel did not help me and I'm pretty good with Excel...SMH...Thank you!
Hi!
Not sure if this will make sense but I NEED HELP!! I have a list of 60 names and their leave. When a cell is populated I need it to turn yellow, when it goes over 15% of the column being populated I want it to turn Red.
I think this is possible with Conditional Formatting but I can't seem to get it to work. Obviously I might be way out but I have created the formula at the bottom of the column so I have one rule to say the cell is less than 64 turn it yellow then a second rule that says if it is greater than 64 turn the cell red. It just doesn't colour any cell.
Is there anything you can help with?
Hello Svetlana,
I would like to format a cell color based on two other cells meeting certain conditional formats. To be specific I have a cell (G16) that will be highlighted in a color based on the value in that cell not being between the values in C117 and D117. I have a second cell (H16) that will be highlighted if the calculated value in that cell is not between C118 and D118.
If the conditions in both G16 and H16 are met, then I want to highlight cell I16 in a second color. Is there a way to do this?
Hello,
Is there anyway to highlight a row based on a cell value that's on another sheet in the same workbook?
for instance, cell B7 in Sheet1 contains a decimal value (in this case, it is 5). And the condition is, highlight the range A2:B6 in Sheet 2. But the cell B7 in Sheet1 is dynamic. Hence if i enter 7, the range A2:B8 in sheet 2 must be highlighted.
Is this achievable through conditional formatting?
Hello,
I have created a live-spreadsheet for Orders with 'Date Required' and 'ETA' columns in them.
I would like the dates in the 'ETA' to be highlighted if they are greater than the dates stated in the 'Date Required' column.
I can get this to work on individual Rows through Conditional Formatting but cannot repeat the process on a large scale through-out the entire sheet.
Please let me know if you can help.
Hi,
Thanks for such a useful page.
I want to extract only year from the date column feed with different formats, but unable to do so.
Please help me with this.
Best Regards,
Zohaib
Hi
I wondered if you might be able to help.
I have a spreadsheet on which I detail all my spending each month with a column for each shop/supermarket.
In A1 I have today's date with the formula / =TODAY() /
In Column A I have the date and have done conditional formatting so that this cell is highlighted if it is the same date as A1.
What I really want to do is highlight (change the colour of) the whole row when the date in column A = today's date.
Thank you
Regards
Chris
Hi Svetlana
Thank you very much for doing this, very clear and easy to follow, much appreciated.
Thanks
Dave
Hi Svetlana,
Can you help please?
I have seen above the following
"I have one column (J) which is "date of sale". This only has a value if a sale has been made. So, I want to highlight all the rows which have a date in column J (essentially highlighting all the rows where I have made a sale, and leaving the ones where the sale has not been closed blank) with your response of Try selecting the whole table and then create the formatting rule with this formula =$J2"" (assuming that your table has headers). It will color all the rows that have any value in column J."
I have a similar issue but its for 2 columns (E and H) but a date will only be in on or the other - never both. hope this makes sense.
would really appreciated your help please :-)
i am trying to make this work with dates in either column e or f
Sorry to trouble you, but I cannot make this work for a date!
I have one column (J) which is "date of sale". This only has a value if a sale has been made. So, I want to highlight all the rows which have a date in column J (essentially highlighting all the rows where I have made a sale, and leaving the ones where the sale has not been closed blank)
Can you help?
Thanks!
Thank you
I found the solution.
=ISNUMBER(Search("p1",S3))
This could be applied to all payments.
Payment 1 Payment 2 Payment 3 Payment 4 Paid 1, 2, 3, 4
Hi!
Thank you for this site that produces excellent information.
I would request your help!
I have a table and one cell will contain (Paid 1, Paid 2, Paid 3).Each will be written after one month. These refer to other cells of payments. (payment 1) (Payment 2) and Payment 3). So I need each cell of payment to be highlighted if I write (Paid 1, Paid 2, Paid 3) in the last cell.
Appreciate your help
Imad
if a column contains "any date" i want to fill a color to the entire row in excel
Hello Naseef,
Select the rows that you wan to highlight, and create a conditional formatting rule with the below formula, where A2 is the top-most cell with a date:
=ISNUMBER($A2)
very helpful thank you!
I am sorry. My question was a bit confusion. Here is the revised one: Are we only able to check one column at once? Is it possible to check entire worksheet for a keyword(s) and then highlight all the rows have hit in different columns?
Hi Mike,
I don't know a way to check the entire worksheet. However, if there are a limited number of columns to check, you can use the following formula to highlight rows that contain a specific text in any of the concatenated columns:
=SEARCH("text",$A1&$B1&$C1&$D1)>0
Where 1 is the top row that you want to highlight.
Are we able to check one column as once? Is it possible to check entire worksheet for a keyword(s) and then highlight all the rows have hit in different columns?
Hi,
I have a table where the text in column N is either "Live" or "Off-hired" and I would like the whole row to be highlighted whenever "live" occurs. I have tried a number of the formulas above but I can't seem to get it to work.
please can you help?
Thank you very much :)
Is it possible to insert icon sets from different sheet in the same workbook
Hi,
I need to change the cell color based on the previous cell value.
For example
A B
1
2
If B2 value is greater than A2, then B2 value automatically change into green color. If it is less than A2, then I need to change into red color like wise it will need to happen when C2>B2, D2>C2 etc…
Is there any way to do this?
Thank you for your help.
Thank you very much. This is exactly what I was digging in Microsoft help center for 30 min.
hi there,
its very nice and helpfull,
Thanks,
Hi there,
so on my Excel, I have color shaded for the status, green for good, red for bad, etc.
Now I need to change those colors to a status value in text i.e. good, bad, opportunity for a migration to a CRM?
is there an easy way to do this for several hunrded entries on Excel?
thanks
Can you please help me, I'm working on a spreadsheet and I want my J4:AI4 to change it font color to red with the following condition: if column G = 10, column I < 17 and column G = 20, column I <7 and the even rows from J6 to J1154 < 0.
I have a spreadsheet that is currently in red font. In column F an x is placed if that row has been edited. Is there a formula that can be used so that when the x is placed in column F the entire row changes to a black color font?
I have four columns. The first one has a name and the next three have numbers. If the first three columns are all 0 I want the name to turn red. Only if they are all 0 though. If just 1 is above 0 it needs to turn yellow. If they are all above 0 then it needs to turn green. Is there any way I can do this?
I have three columns ("Invoice Inc. VAT", "Credit Inc. VAT" and "Balance Inc. VAT").
I would like to have the values in the "Balance Inc. VAT" column to be displayed in red when the other two columns ("Invoice Inc. VAT" and "Credit Inc. VAT") are not equal.
When the values in the "Invoice Inc. VAT" and the "Credit Inc. VAT" columns are equal, I would like the values in the "Balance Inc. VAT" column to be displayed in black.
I have tried two Conditional Formatting rules (one for "Less Than" and one for "Equal To") but all the values in the "Balance Inc. VAT" column just show red.
Pleas can you help?
I have three tabs, one (Definition Tab) having definitions like Small, Medium, Large, & X Large and Time to complete work for each size in weeks are 3, 4, 6 and 8 respectively. The second tab (Forecast Tab)has weeks in columns starting week 1 till week 53 of an year and 4 Rows as Small, Medium, Large and X Large. The third tab (Customer Tab) has customer name, Size, resource name, work start week, delay if any, total weeks as columns and each row represent different customers.
I want to have the rows in second tab (Forecast Tab) highlighted with colors. For eg: if size of a customer is Large (6 Weeks), work start week column is having value 8, & delay if any has value 3, 9 (6+3) columns against a newly added row in forecast tab need to be highlighted with Yellow automatically. Like wise, any input modification done to the customer tab, based on definitions, the forecast tab should get a row added under the weeks accordingly.
Appreciate your help is getting this using Excel 2010 or above.
thanks in advance.
Krish
I want to change the font color of cells if the Status is "NO REPLY". How will I do that?
CUSTOMER NAME PRODUCTS PIC STATUS
ABC 123 JOHN NO REPLY
DEF 456 MIKE PLACED AN ORDER
I Need help from u
i wants color to colum in 1-10 then after 10-20colum i needed to give another color how can i?
I have two columns with dates. I have shaded the first column with some specific dates. I want to shade same dates in the second columns with the help of some formulas.
Thank you
Hi,
I use excel to create daily reports for my team. It involves copying data from an internal site and pasting it into excel so i can manipulate it and make it useful for us. The problem is the data comes with links (which I need). This ruins any conditional formatting I may have on the template used to create the reports.
Is it possible to keep the source formatting and have text in a single cell change the color of a row?
HI, i have data in two column in one excel sheet, now in another sheet i am linking the same data by clicking + sign. But Data is linking but the problem is: when i changed cell color in one sheet its not changing in another excel sheet particularly for that cells only
pl help
Peoples i need help as i suck with excel.
I would like a row to be highlighted if there is nothing in the last two cells of that row. However there would be data in each of the other cells in said row.
Hi Svetlana,
there are two things GOOD & BAD (say 2 ROWS)
I want a formula that will make "BAD" row Backgroud RED in color and NO COLOR IF GOOD
So Is it possible that certain formula for colors exist?
Regards,
Savinn
Apologies. The formatting formula we are using is "$C2>0", cheers. Z
Dear Sir,
This is a very valuable post. I learned a lot from it.
I was wondering if there is a way to change the color of a cell "Only" when the value of the sell change from a certain value to another, without changing other cells that got same value under the same formula.
I will try to explain better: I have "Stock" column which has only one of two values in its celle: either "0" or "10".
Items that are out of stock have value of "0" while any other item that is in stock (or comes back to stock) get value updated to "10" because we never re-stock items less than 10 units minimum in quantity.
My issue is not by having items becoming out of stock because we have a control on this. The issue is that some items come back to stock but we never notice early, therefore we miss the chance to increase the quantity as the quantity will remain zero in the marketplaces we are selling our items on.
With your code, I was able to use formula "$C2<0", however, it changes to color to all items that we have "10" in quantity, regardless whether they were already having "10" or got updated from zero to ten, making your formatting formula not very beneficial to me.
Is there a way to highlight only the cells that specifically get values updated from zero to ten without affecting the cells that already got value of "10" in first place?
I look forward to hearing from you or anyone else who has the knowledge of dealing with this matter.
Best regards,
Zed Sefi
I am using the following formula that I pieced together after some research online. It seems to be working in the example I tried it on, but I don't fully understand the entire formula. I want to interpret so I can figure out whether or not it will work for similar checks and balances. The formula and reason are as follows:
=AND(ISBLANK($D5)=FALSE,NOT(ISNUMBER(MATCH($D5,$E5,0))))
Looking for a cond format that will fill column D if its respective C cell is not the same value/text (d1="x" and c1=""), but will not fill is column d is blank, d and c are blank, and d and c match.
Can you help interpret the formula and if it will work for an entire spreadsheet comparing 2 columns (separate conditional formats)?
Hi Svetlana
Not from want of trying, I have failed to have a colour of a row changed from red to green if column F has a number in it
On another sheet I would like to mark the whole row as green if the number in column R is greater than 65.
Please help
Darcy
How to change automatically the text color based on a cell's matched text in Excel
pleas sand me condition formatting function.
IF
AND
IF(AAAA,)AND)
Hi
If I want to highlight any cell in the column that contains a number larger than the previous one in the same column, what should I do?
Hello, Gloria,
Please try the following:
Go to Conditional Formatting -> New Rule -> Use a formula to determine which cells to format
Enter the following formula:
=AND(ROW(A1) <> 1, A1>OFFSET(A1, -1, 0))
Hope this helps.
Hello Maria
Thank you for your above explanation.
My predicament is the same as Gloria's "If I want to highlight any cell in the column that contains a number larger than the previous one in the same column, what should I do?"
I have tried your formula and I cannot seem to get it to highlight the cell.
In the example below, I would like to see -11.41 and +3.09 highlighted, because in both instances the cell above it, is >10 value points away from it.
-33.22
-26.75
-22.19
-11.41
-8.21
+3.09
+8.03
What would my formula be? To make it easier for me to work with, the nominated cell numbers are:-
-11.41 is H51
and
+3.09 is H53
I hope I am making sense :)
Many thanks
David
Is it possible to use conditional formatting to put a coloured border underneath a row where the date in column A changes.
So if you had a table with:
14-01-16
14-01-16
15-01-16
16-01-16
It would put a different coloured border under each different (unique) date.
Hi
I want to color my a row which contain "E" in a cell of that row.
please provide me a solution for my problem
I want to colour my employee id numbers with red and green which is randomly upto 1200 numbers anybodycan you help me to make conditional format on this
Hello Rathna!
Please use the Home Tab -> Condition Formatting -> Color Scales command
You can use the "More Color Scale Rules" additional command to define a custom "2-Color Scale" format style.