I've tried searching low, high, and deep within the crevices of the internet to find a possible solution to this, but have had no luck. My main goal is to highlight individual cells based on a couple criteria. I have a google sheet that tracks jobs based on input from employees. My conditions are:
Date must be before today
Cell must be empty (no input from that day)
Only the cell that is empty should be highlighted
https://docs.google.com/spreadsheets/d/10W9O55QQ31acOj5SyKcE0CXx8S78MZQtY-sRaIKgB7c/edit?usp=sharing
The goal of this is to make cells that did not receive any data stand out. The current formula I have is
=AND(ARRAYFORMULA(ISBLANK($B3:$D3)), ARRAYFORMULA(ISBLANK($I3:$K3)), $A3<TODAY())
But this is only highlighting the entire row, and when a cell in that row is filled, it no longer highlights that row. The yellow row is today's date. Any help in solving this is greatly appreciated!
It's not 100% clear what should be happening with the merged Column E:H. But from the limited data and assigned colors I see in your sheet, try swapping out your current "pink" custom CF rule with this one:
=AND($A3<TODAY(), OR(AND(COLUMN(B3)<=4, B3=""), AND(COLUMN(B3)>=9, B3=""), AND(COLUMN(B3)>4, COLUMN(B3)<9, OR(B3<>"", JOIN("",$B3:$K3)=""))))
You need to set a conditional format rule for each column
I believe here are the conditional format rules you need:
Apply To Range
Formula
A3:A
=AND(OR(ARRAYFORMULA(ISBLANK($B3:$D3)), ARRAYFORMULA(ISBLANK($I3:$K3))), $A3<TODAY()) *Note the OR
B3:B
=AND($A3<TODAY(), ISBLANK($B3))
C3:C
=AND($C3<TODAY(), ISBLANK($C3))
D3:D
=AND($D3<TODAY(), ISBLANK($D3))
I3:I
=AND($I3<TODAY(), ISBLANK($I3))
J3:J
=AND($J3<TODAY(), ISBLANK($J3))
K3:K
=AND($K3<TODAY(), ISBLANK($K3))
The key concept here is that within one rule you cannot specify specific ranges to apply the rule to. Part of the definition of the rule is the range that it applies to. You can have rules that take precedence over certain ranges, but you cannot have two ranges in one rule. You can test many ranges in one rule, but the formatting applies to the whole range the rule is applied to.
Make sure you have deleted previous rules before applying these to make sure they don't take precedence
Reference
Conditional Formatting
Related
How can i highlight objects that appears within 30 days by conditional format in google sheet ?
Column A contain date and Column B contains objects.
(only objects need to get highlighted)
thanks in advance. here a link shared to the sheet
https://docs.google.com/spreadsheets/d/1bdWKHtW6SA6XI5pIZUrlLQJLi-Gywx2iYUqxFWY1e0I/edit#gid=0
one more sheet added ('estimated output') where you can see how the output must be. please have a look. thank you
As far as I understood, there are two conditions that must be met for a cell to be highlighted:
The object inside the cell must be repeated in that column.
A date between an object must be 30 days apart from the date of a repeated object.
This behavior can be accomplished with the following formula, which you can plug in as a custom formula in a Conditional Formatting rule:
=AND(COUNTIF(B$2:B$7,B2)>1,COUNTIF(TRANSPOSE(ARRAYFORMULA(IF(B$2:B$7=B2,ABS(A$2:A$7-A2),false))),30)>0)
The first part (COUNTIF(B$2:B$7,B2)>1) makes use of the COUNTIF formula to ensure that the object is repeated (that there are more than one instances of it). The second part uses an ARRAYFORMULA to enumerate the differences between dates with an IF clause to make sure those dates correspond to the same object, and then the COUNTIF formula is used again to check that there is at least one instance of those differences being 30. Finally, those two conditions are combined with an AND formula.
Beginner here!
Here's a spreadsheet trying to show what I mean.
Suppose I have data for metrics in comparison to my competitors.
The metrics are sorted highest to lowest and I want to turn the names of the other companies into "Company 1, Company 2, etc." along with the order of the metrics. Myself ("Me") remains unchanged.
With every data set the competitors could be different companies, and I could be ranked in a different position. The number of competitors could range from 1-20.
Is there a way to automate the green fields in the spreadsheet so that I can just paste the data and the competitor numbering stays constant no matter where I appear in the list?
Thank you!
Lighter Torches, I've added a sheet named "Erik" to your spreadsheet.
I've placed an array formula into two cells: G5 and J5. They are the same except for the relative cell references. Since it is an array formula, the single formula in G5 "runs" the entire data set generated in G5:H; likewise, the formula in J5 "runs" the entire data set generated in J5:K. Array formulas do not require dragging/copying to other cells.
Here is the G5 formula:
=ArrayFormula(QUERY(SPLIT({"Me"&"^"&IFERROR(VLOOKUP("Me",A5:B,2,FALSE),"NA");"Company "&ROW(INDIRECT("A1:A"&COUNTA(FILTER(A5:A,A5:A<>"",A5:A<>"Me"))))&"^"&SORT(FILTER(B5:B,A5:A<>"",A5:A<>"Me"),FILTER(B5:B,A5:A<>"",A5:A<>"Me"),FALSE)},"^"),"Select * Order By Col2 Desc"))
In your sample data, the companies are already ordered by rank, best to worst. But in the real world, it seems that may not always be the case. With that in mind, you'll notice that I moved your top performer to the bottom in the second data set. I've written the formulas to account for this (i.e., they will order the companies in the correct order whether they were originally in the correct order or not).
Also, if "Me" for some reason doesn't appear in a raw-data list at all, it still shows up, unranked, at the top of the generated list. Again, I tried to account for real-world what-ifs in the formula.
Finally, I added a sheet-wide custom Conditional Formatting rule that applies bold to any occurrence of the word "Me," since it seemed you were doing that manually. As such, you can type the sole word "Me" in any cell in the sheet, and it will automatically be formatted bold. You can see this rule by selecting Format > Conditional Formatting from the menu, then clicking on the rule you see in the window that appears.
How to match format of matching value? *Google Sheets
https://i.stack.imgur.com/xeZmS.png
If I understand your question, I think I have an answer for you. See sample sheet here:
https://docs.google.com/spreadsheets/d/1QhED3qsoUiX0Km8R86Rg6kHdKdjwQW0uhHZeOd40Sy4/edit?usp=sharing
Note that this currently requires one formula for each of your due date columns, but these are easily dragged across, from D10, for as many columns as you need. There may be a way to combine them as one, but I haven't figured that out yet.
This conditional formatting rule's formula is applied to include D10:D and across as many columns as you need - D10:I18 in this sample sheet.
=arrayformula(index($A$2:$C$18,match(D$9&D10,$A$2:$A$18&$B$2:$B$18,0),3))
which combines the date and the item name, finds them in the initial data, and sees whether the Paid checkbox is ticked. If yes, it formats the text as "strikethrough". For clarity, I've also formatted the cell to gray, but this is easily removed, in the formatting options for that conditional formatting rule.
REFERENCE:
INDEX
ARRAYFORMULA
Conditional Formatting rules
I have 6 columns and ~200 rows of numbers on one Google Sheet. Then on the other is also 6 columns but only 3 rows. I am trying to use conditional formatting to highlight the numbers in the larger group if they match any of the ones one my other sheet of data.
I've gotten it for matching one number, but having it look at a whole set is proving to be more difficult.
try on range A2:E:
=(REGEXMATCH(TO_TEXT(A2), "^"&TEXTJOIN("$|^", 1, $G$2:$K$5)&"$"))*(A1<>"")
Conditional formatting Apply to range A:A use the following custom formula:
=or(A1=$G$1,A1=$G$2,A1=$G$3)
This will be the easiest way to do it, of course if you have a lot of matches you want to make then it will become more and more difficult without a helper column... Your example only has 3 matches per column so this will work but if you have hundreds of matches you will need to basically make a column looking up if there is a match and conditional formatting based on that (it will be a lot easier and cleaner).
Sheet regarding this question.
I have a set of sheets where each person must use a drop down box to select a house they would like to view. We can easily add a house to the list by inserting the address, and a URL into the "houses" sheet and it will be shown in the dropdown list and the results table.
Everything works so far, but if a house becomes unavailable, I want to mark it unavailable on the "houses" sheet, and then all occurrences of that specific house in the dropdown cells and results section should have a red background.
I could use conditional formatting, but this would require me to apply a different formula to each cell and that wouldn't be practical.
I regret not elegant but I think your layout is not well suited to Google Sheets' strengths. The best I can suggest is in say J2 of sheet Choices:
=vlookup(B2,Houses!$A:$C,3,0)
copied down to J30 and J2:J9 copied across to ColumnN. Then select Choices ColumnsB:F and Format - Conditional formatting..., Custom formula is and:
=J1="No"
with formatting of red background Done.
You might want to hide columns J:N.
You should just use conditional formatting.
Step 1: Select Cell B2, go to conditional formatting and create a new rule, "Use a formula to determine which cells to format".
Step 2: Use the following formula:
=VLOOKUP(B2,Houses!$A$3:$C$42,3,FALSE)="No"
Note: This B2 value since it isn't using $, moves dynamically depending on what cells your formula is applied to. The VLOOKUP looks up the B2 value in the depicted range and returns the 'Available' column (column 3 on the Houses sheet). We're matching on "No" specifically, I believe its case sensitive so watch out for that caveat.
Step 3: Set your format to Red.
Step 4: Make sure your 'Applies to' box is pointed to the following range:
=$B$2:$F$9
Personally I hate hard coded ranges like these, you should look into dynamic named ranges. That way you can just reference a named range instead of the A3:C42 range for both your Data Validation dropdown as well as these formulas.