Conditional formatting not working when value is pasted - google-sheets

I'm using Google sheets. I just want the cell to turn green when there is something in it. Pretty basic. It works if I type a value in but not if I paste a value from somewhere else. The ID numbers I'm working with are long so I don't want to retype them because it wastes time and creates room for error.

To preserve conditional formatting when pasting to a cell, you can do one of the following
Choose Paste values only
OR
Double click within the cell and paste your value/number

Related

Making a task list that, when clicking a checkbox, a task fully gets grayed out but having trouble copying the conditional formatting

Essentially just as the title says, I'm making a task list with a "Finished" category that has checkboxes. The way I currently have it set up is that, with the conditional formatting, when you hit the checkbox, the entire row gets grayed out as the task has been completed.
Since it's a big list, however, I don't want to have to go through and do the conditional format rule for each and every row as it descends. I thought I could just do the normal drag down thing but when I try to, it doesn't change to the appropriate cell number in the formula that's in the conditional formatting rule.
I've attached some screenshots of what I'm talking about so, if anyone can help me figure out how to do that, that'd be amazing, thank you!
What the sheet looks like
Conditional Formatting Rule
Set the range to B3:J100 (or whatever range you want the CF to be applied to) and use as a custom formula
=$K3=TRUE
This rule should work for all the rows in the dedicated range.

Conditional formatting Google sheets, if formula not used

I am trying to highlight cells which have been manually entered by using the formulatext() function. However, at the moment this is highlighting all the cells that have a different outcome (from if statements) to the first cell. Can this be changed?
(If curious my exact formula at the moment is =formulatext(E4)<>if(B4= "","",if(left(CN4,1)<>"-",if(or(D4="A",D4="B"),if(AF4<>"","DONE",CN4),if(AF4<>"","DONE",CN4)),if(or(D4="A",D4="B"),if(AF4<>"","DONE","over 48h"),if(AF4<>"","DONE","over 36h")))), the formula inside is working so no need to change it)
https://docs.google.com/spreadsheets/d/1kOJf07eoe_8tYR9a2h1iv2OIBt77xprHiGER3InGg-g/edit?usp=sharing
I hope that link works.

Google Sheets Conditional Formatting Issue

I am making a google sheet to track attendance for a team. I want the row with the name to highlight a specific color when a checkbox is on. I managed to write something that works for the specific row I'm working in, but any time I try to copy it over to other rows the range is just adjusted, so any time any checkbox from a column is on it highlights all the rows. Attached are pictures that show what I want it to do. I just need help figuring out how to copy this to other rows and keeping them all separated.
The code that is in each conditional formatting is this:
=$B2=True
=$C2=True
=or($D2,$E2)=True
https://docs.google.com/spreadsheets/d/1zwkuJOCBPIIoQ7cp0bV5IvidMVwdeIC0dShdjwKMSkE/edit?usp=sharing
I think the issue is with the code itself because when I copy it adds the new range, but the code stays the same.
your formulae are correct. change your range A2:E2 to A2:E - that will solve it

stop Google Sheets from reformatting/structuring cell formulas

I have some formulas in a Google Sheet cell. If I restructure the formula, like by adding new lines or spaces, for legibility, it undoes my changes. Is there a way to stop this? It seems to only happen if the cell had the formula before. If I put the formula in a new cell it doesn't do that.
This is on Enterprise G-Suite so I cannot share an example sheet.
Blank cell:
Add a structured formula:
Now if I edit the structure it does not retain the changes. In the example below, I removed a new line after TRUE.
Before hitting enter:
After hitting enter:
Also, if I add the same formula to a new/different cell, regardless of how I structure it, it'll restructure to match the one from the other cell.
Google Sheets remembers forming even upon deletion/insertion in new cell. the only way how to achieve what you ask is to introduce a change that directly affects the output calculation. if the output calculation remains the same after the change in structure/formatting then your only possible option is to use lowercase for formula. in other words, if you change your IF to if or If or iF it will register it as new change and therefore the formating will be not reverted to the previous existing state.
the less preferable but working solution would be to wrap it in some useless formula. for example:
=QUERY(IF(TRUE, "hello", "bye"))

Google spreadsheet: Remove conditional formatting, but keep the format

Is there a way to remove the conditional formatting from cells, while keeping the applied format intact?
The only way I've found is:
Copy the cells.
Clear formatting on the cells (ctrl + \)
Paste special -> Paste format only (paste over the said cells).
Copy a cell that has no conditional formatting
Select the cells with de conditional formatting you want to delete
Click Edit > Paste special > Paste conditional formatting only.
Yes, to remove individual conditional formats while leaving other formatting unchanged, in Google Sheets:
If the conditional format pane on the far right is present, close it by clicking the X in the top right of the pane.
Highlight the range of cells (or select a single cell if you want to remove conditional format for only 1 cell) that have conditional formatting applied. For this to work, at least one of the cells you've highlighted must have conditional formatting defined.
Right click the highlighted cells and select "Conditional Formatting" from the context menu.
A vertical panel on the right will appear with a list of conditional format rules that are present in the highlighted range.
Hover the cursor (do not click -- just hover) over the rule you want to delete. As you hover a trash can icon will appear.
Click the trash can icon to remove that particular conditional format.
Copy the required range to another sheet and paste special, values only. Then immediately paste special again, formatting only.
If you want to keep the work in the same place on the same sheet, just cut instead of copy, and then do the above paste operations to the same place.
The advantage of the first method is that by creating a copy you can't accidentally mess up your original and can always replace this when you are satisfied with the result.
I know this is an old question, but I tried the approaches suggested. They don't work. The conditional formatting 'çonditions' are also copied across.
My Solution is to copy and paste into excel and then copy the values back into google sheets.
When pasting into excel the 'conditions' don't get copied over.
Some Redditor saved the day!
Here's the link
function clearFormatting () {
var s = SpreadsheetApp.getActiveSpreadsheet();
var ss = s.getActiveSheet();
ss.clearConditionalFormatRules();
}
To add to the most-voted answer, you can actually do this on an entire sheet, in case that's helpful. (Mac keys shown here)
Command-a to Select All
Command-c to Copy
Command-\ to Clear Formatting
Command-Option-v to Paste Format Only
Without a script is possible with a hack: copy into say Word and back again.

Resources