I want one cell that's blank to change colors based off another cell containing text. But once the blank cell has a text put in I want the color to go away. I have not tried anything because I'm unsure how to code this.
So if
A1(contains text),B1(blank cell) turns red. Once B1(contains text), B1 turns white.
I only want B1 to turn red if A1(contains text).If A1(is blank) I want B1 to stay white.
Format -> Conditional Formatting -> Apply to Range B:B
Custom Formula is =and(A:A<>"",B:B="")
if column A has a length greater than 0 and column B has a length equal to 0 make column B red.
Related
I am using google sheets. For column E, under the header “Received” I have formatted it so that when you type in "no" the color of that cell turns red. But when you type in “yes" then the color of the cell will change to green.
How do I get column F (column to the right of Column E, under the header “Total”) to automatically display the number "20" AND also the make it’s cell
turn to green whenever the cell next to it, in column E says "yes"? And if I type in “no” in Column E id like the cell next to it in Column F to say “0” and the background color change to red.
Please help!
I asked ChatGPT it said to use the formula =IF(E2=“yes”,”20”, “”) however this didn’t work. It only changed column F background color to green but it didn’t change the cell to say “20”
These are two separate things. One is the formula inside the cell that determines the value of 20 or 0
=IF(E2="","",IF(E2=“yes”,20,0))
Or you can set it as an array formula in F2 to expand to lower rows. Put this in F2:
=ArrayFormula(IF(E2:E="","",IF(E2:E=“yes”,20,0)))
Other thing is the conditional formatting rules that set the colours. Select F2 column and choose conditional formatting. Look for custom formula and you can use:
=E2="yes"
=E2="no"
For green and red respectively. Try these things and let me know
I was able to to get it right using the formula =IF(E2="yes", "20.00", "0.00").
That did the trick, and to change the colors I did conditional format and set it to Text contains: 20and changed the color to green. I added another rule except this time I put Text contains: 0.00 and changed the color to green.
What I try to do is to give a GREEN color to a cell in a row if the previous cell is less and RED the cell is less than its previous:
Please check this video to illuminate what I want to describe:
https://www.loom.com/share/46470e78ae7b49699ce83d7c268dd459
Conditional formatting on row range in Google Sheets
The problem is that, as seen in the video and the screenshot, the conditional formatting cell references do not change when applied to a row, even if I did not use $. How can I manage to have relative references for each cell to its previous in a row?
For example, when setting GREEN color if the cell C1 is greater than B1 (IF =C1>B1 set the color GREEN), in the next cell D1 the conditional formatting should automatically be referencing: IF =D1>C1 set the color GREEN.
If you want to apply to the columns C and D, set your Apply to range to C:D.
Set 2 conditions with Custom formula is:
for the green styling: =AND(LEN(C:C),B:B<C:C)
for the red styling: =AND(LEN(C:C),B:B>C:C)
If you need to expand over more column, just expand the range.
I am trying to create a pixel art activity where a specific number in a cell will turn a different cell a colour if the correct answer/ number is input.
For example if cell C2 has the correct answer of 7 then cells E1,F2, and G3 would turn Red.
Then if cell 2 has the correct answer of 22 cells F1,G2, and E3 would turn blue. But any other number would not change the colour of those cells.
try like this with custom formula:
=$C$2=7
welcome to stackoverflow.
For example in cell C2 apply this rule
Format cells if: 'Custom Formula is' (dropdown)
= E1 = 7
now C2 should get formatting when E1 equals 7.
Note that for strings you will need to use double quotes, like this:
= G2 = "k"
Finally, if multiple cells need the same rule, you can click the squares icon in the 'Apply to range' input field, and then you can hold 'control' and click multiple fields.
I want to change format of cell A1 colored green , depends on the value in cells (A2:A5) if all cells value is "Done" , I want to color A1 Green.
Approach:
Now you are checking only the cell A2. You should check all the column range.
Your idea is to make your header green when all the cells contain the word "Done". You can translate this idea to: I have exactly 0 cells that don't contain the word "Done". This way you won't have to keep track of how many cells are in your column.
You can count how many values respect a criterion using the function COUNTIF.
Formula:
=COUNTIF(A2:A5, "<>Done") = 0
So I want the following conditions to be achieved based on the value of an external cell:
If the text in the external cell coincides with the one in the selected cell, the selected cell turns green. [DONE with Format Rule: Is equal to =externalCell]
If the text in the external cell does not coincide with the one in the selected cell, the selected cell turns red. [DONE with Format Rule: Is not equal to =externalCell]
If there is no text in the external cell, the selected cell turns white. [PENDING]
Please see the screenshot in the link for a better understanding, where you can see my conditional format rules.
In this case, selected cell J10 is green because coincides with external cell T10. It would be red in any other case, but don't know how to supply the third condition.
EDIT: Let's explain it with an example. What I want to do is that:
(A1 will always have text)
A1 turns colour white when B1 HAS NO text in it.
A1 turns colour green when B1 HAS text in it and the text in both cells match.
A1 turns colour red when B1 HAS text in it and the text in both cells DO NOT match.
(A1 will always have text)
A1 turns colour white when B1 HAS NO text in it.
A1 turns colour green when B1 HAS text in it and the text in both cells match.
A1 turns colour red when B1 HAS text in it and the text in both cells DO NOT match.
try it like this: