Google Sheets Conditional format on entire column - google-sheets

This has been answered
I currently have it set so if anything in A1:Z10000 reads red then it will be highlighted in Red with conditional format. the only problem is that only applies to the single sell that reads Red. What I would like for it to do is if A9 says Red then all of 9:9 is highlighted in Red.
Thanks for any help with this
A public functioning version of the sheet can be found here https://docs.google.com/spreadsheets/d/1N13pkCZmJ6rHFXjH3rl-dPHNdo_N4zQbH5jps1jIQoc/edit?usp=sharing

Please try a CF formula rule of:
=countif($A1:$Z1,"red")
with the Apply to range as you show.
Choose formatting also.

In order to solve this I used =$A2="Red"

Related

Google sheets conditional formatting range of dates

I'm trying to highlight cells based on a range of dates so that one can visually see from what month to what month one unit plan takes.
Please see this page (row 9) as a reference: https://docs.google.com/spreadsheets/d/1VDE1IdRJ7EB59NDos_A7DEUBm5LA75akbqiRVoH5IkI/edit#gid=222884255&range=G9
For example, if a unit goes from 4/2023 to 6/2023, I'd like April, May, and June boxes to be highlighted. I used the "custom formula" option in conditional formatting and input this formula:
=AND(($G$9:$R$9>=$E9),($G$9:$R$9<=$F9))
However, nothing is lighting up for me. The dates I'm using come from another Sheet (Grade 7). Could that be an issue?
Any help would be greatly appreciated. Thank you!
Hoping to see highlighted cells but the colors are not showing up.
I tried this formula: =AND(($G$9:$R$9>=$E9),($G$9:$R$9<=$F9))
Your sheet is not public, from what I guess, you may try with next formula for the whole range. It will automatically expand G to R:
=AND((G$9>=$E9),(G$9<=$F9))

Dynamic Conditional formating based with a custom formula

Ok, it's a bit of a head scratcher for me.
I am working on a work load spreadsheet and I need to highlight people with different colours depending on their workload so that I could see at glance who's loaded too much and who still has capacity.
Capacity number is just a number of project she or he can handle can be 3 to 5. I store this data in a separate sheet "Resources".
3 colours of load are enough
The problem I am facing is conditional formatting in GS doesn't support pulling data from a separate sheet. Id' rather keep all the raw data outride of the main Overview sheet. But if it's impossible maybe helper columns next to each group of workers would work as well
However, it's important be able to copy the whole row and paste at the end for new projects.
Plus I have difficulty to figure out how to create a formula that works for all names, rather than creating colour conditions for each single name.
Any suggestions?
Here is an example spreadsheet of table and bellow what I envision it should like. I need to be able to see in the Overview sheet at glance who's at their capacity. So as you can see Bobbie is on 6 projects, so he has to be RED. Tom is only on one project and the colour should be something like blue or green. Hope that makes sense https://docs.google.com/spreadsheets/d/12hJlsH8PndCYrrhgCoL5oUghHQMLL1bgIWomSpEfdEA/edit?usp=sharing
Okay, I think I found a way to do this. However, it needs a couple of Conditional format rules if you want to do a kind of gradian.
The good thing is that it will not require to be linked to a name. Even if you change the names, it will not affect it.
The rule will look something like this:
The one that has a capacity of up to 5 will look like this after adding the rules:
For the ones for developers, I added the 3 columns at the same time, so the formula takes the 3 columns for the capacity count.
I edited the Sheet called "Copy of Overview." I added the formatting for the C and D columns.
Reference:
Use conditional formatting rules in Google Sheets
Quick fix
Try this if you want the conditional formatting done in Resources tab.
Adjust the minpoint and maxpoint in Conditional format rules pannel accordingly
Helper table
Paste this formula anywhere to get the helper table with the count of each worker occurrence in the range C2:F
= ArrayFormula({
"Name", "Work Load";
FILTER(UNIQUE(FLATTEN(Overview!C2:F)),UNIQUE(FLATTEN(Overview!C2:F))<>"",UNIQUE(FLATTEN(Overview!C2:F))<>"-"), IF(
FILTER(UNIQUE(FLATTEN(Overview!C2:F)),UNIQUE(FLATTEN(Overview!C2:F))<>"",UNIQUE(FLATTEN(Overview!C2:F))<>"-")="",,
COUNTIF(FILTER(FLATTEN(Overview!C2:F),FLATTEN(Overview!C2:F)<>""), FILTER(UNIQUE(FLATTEN(Overview!C2:F)),UNIQUE(FLATTEN(Overview!C2:F))<>"",UNIQUE(FLATTEN(Overview!C2:F))<>"-")))})
Conditional formatting & formulas - Simple
Similar to Giselle Valladares, answer "2022-08-12 22:00:41Z"
Simple but have a Limitation: a single white space is also highlighted
Color "Formatting style"
Apply to range
Formula
Green
C2:G
=COUNTIF(C2:F,C2)=1
Blue
C2:G
=COUNTIF(C2:F,C2)=2
yellow
C2:G
=COUNTIF(C2:F,C2)=3
Red
C2:G
=COUNTIF(C2:F,C2)>=4
Conditional formatting & formulas - Complex
Try this
Color "Formatting style"
Apply to range
Formula
Green
C2:G
=ArrayFormula(REGEXMATCH(Overview!C2:G23, TEXTJOIN("|",,FILTER(FILTER(FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-"),FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-")<>""),FILTER(IF( FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-")="",, COUNTIF(FILTER(FLATTEN(Overview!C2:G),FLATTEN(Overview!C2:G)<>""), FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-"))),IF( FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-")="",, COUNTIF(FILTER(FLATTEN(Overview!C2:G),FLATTEN(Overview!C2:G)<>""), FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-")))<>"")=1))))
Blue
C2:G
=ArrayFormula(REGEXMATCH(Overview!C2:G, TEXTJOIN("|",,FILTER(FILTER(FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-"),FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-")<>""),FILTER(IF( FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-")="",, COUNTIF(FILTER(FLATTEN(Overview!C2:G),FLATTEN(Overview!C2:G)<>""), FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-"))),IF( FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-")="",, COUNTIF(FILTER(FLATTEN(Overview!C2:G),FLATTEN(Overview!C2:G)<>""), FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-")))<>"")=2))))
yellow
C2:G
=ArrayFormula(REGEXMATCH(Overview!C2:G, TEXTJOIN("|",,FILTER(FILTER(FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-"),FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-")<>""),FILTER(IF( FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-")="",, COUNTIF(FILTER(FLATTEN(Overview!C2:G),FLATTEN(Overview!C2:G)<>""), FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-"))),IF( FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-")="",, COUNTIF(FILTER(FLATTEN(Overview!C2:G),FLATTEN(Overview!C2:G)<>""), FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-")))<>"")=3))))
Red
C2:G
=ArrayFormula(REGEXMATCH(Overview!C2:G23, TEXTJOIN("|",,FILTER(FILTER(FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-"),FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-")<>""),FILTER(IF( FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-")="",, COUNTIF(FILTER(FLATTEN(Overview!C2:G),FLATTEN(Overview!C2:G)<>""), FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-"))),IF( FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-")="",, COUNTIF(FILTER(FLATTEN(Overview!C2:G),FLATTEN(Overview!C2:G)<>""), FILTER(UNIQUE(FLATTEN(Overview!C2:G)),UNIQUE(FLATTEN(Overview!C2:G))<>"",UNIQUE(FLATTEN(Overview!C2:G))<>"-")))<>"")>3))))
The problem was:
First, you applied your conditional formatting to whole columns when your first row is a header.
Second, your NB.SI formulas had the same problem as the first one but also you didn't lock your ranges with "$".
So for managers, the formula must apply to the range C2:C (not C:C) and be written like that:
=NB.SI($C$2:$C,C2)>5
The ">5" must be modified according to the colors you want.
For the Designer, you can add the function "IF" to the formula as Daniella has more capabilities like this:
=SI($G2<>"Daniella";NB.SI($G$2:$G,G2)>3,NB.SI($G$2:$G,G2)>4)

PhpSpreadsheet Conditional formatting (Squared)

I am new to php programming area.
I have a question, I would like to use conditional to format a column, for example if the values of Column B are different to the squared ones of each value of Column A then change the background color red if everything is right change to green.
Please I need a help
See phpspreadsheet documentation here.

Google Sheets conditional formatting based on relative reference using another sheet's cell values

Using Google Spreadsheets, Excel doesn't seem to have the same problem.
I have a 100-cell column; In that column, I need every cell to check relative reference using another sheet's value. The problem is that conditional formatting seems to only accept INDIRECT, which unfortunately doesn't support relative reference.
I need Cell B3 to check Sheet2!$G3, and see if it is higher than 0, and if so, let the cell be green.
Therefore I want Cell B4 to check Sheet2!G4; Ergo Cell B5 to check Sheet2!G5, and so on.
I haven't seen the issue to be addressed yet, will appreciate anyone's help.
try:
=B1>INDIRECT("Sheet2!G"&ROW())
A basic formula-based CF rule works fine (in Excel)
EDIT - this worked for me in Sheets
=indirect("Sheet2!$G" & ROW()-2)>0
EDIT2 - on preview #player0 already has that

Logical AND for Conditional Formatting in Google Spreadsheet

I have been doing a lot of research regarding this but it seems my formula is not working. I was trying to check two cells. One cell should not be empty and another cell should be less than or equal zero and what it does is it changes the color of the text of a certain cell.
Please see picture below for reference.
I have an existing conditional formatting which checks D5:D29 if it's not empty and changes the color of E5:E31 to Blue. See formula : =NOT(ISBLANK(D5:D29)) - this is working great.
Problem:
I'm going to check cell D5:D29 if it's not empty and I'm going to check E5:E31 if it's less than or equal to zero. If both are TRUE, the color of the text in E5:E31 changes to red. Formula : =AND(NOT(ISBLANK(D5:D29)),(E5:E31<=0))
Please see picture below. My formula is not working. Is there something wrong in it?
Short answer
The problem is on the references being used.
Instead of D5:D29 and E5:E31 use D5 and E5 when to the conditional formatting formula applied to E5:31
Explanation
Conditional formatting formulas applied to a range of cells, should be written having in mind the top-left cell. The spreadsheet engine will "automatically adjust" the formula for the other cells in the range.

Resources