How to apply this Excel formula to work with Conditional Formatting - excel-2010

I am trying to apply the formula below (which is correct as far as I know) to conditional formatting, but it doesn't seem to be work properly. Any suggestions on how to fix this formula so that it works for conditional formatting would be greatly appreciated.
OR(AND(NAs!$A2="x",NAs!$AD2<TODAY()),AND(NAs!$A2="x",NAs!$AD2=""))

=AND(NAs!$A2="x",NAs!$AD2<TODAY())
will work as a CF formula rule for at least a single cell. More than that and you need to disclose what it is you want.

Related

Google Sheets, how can I remove or strip specified strings

I'm using Google Sheets and trying to figure out a formula that strips or removes specific strings. So a cell might have:
[url=https:website1]https:website1[/url] [url=https:website2]https:website2[/url]
and I want to convert it to
https:website1 https:website1
Each cell in the column will have different "websites" but the formatting will be similar. Any help is appreciated.
I've tried REGEXEXTRACT and SUBSTITUTE functions but can't seem to figure it out.
can you try:
=BYROW(A2:A,LAMBDA(ax,IF(ax="",,TEXTJOIN(CHAR(10),1,INDEX(REGEXEXTRACT(SPLIT(ax,"[url=",0,0),"[^\]]*"))))))

How to combine these arrayformula and formula in custom formatting rule in just 1 formula in custom formatting rule?

I'm using an array formula to find conflicts in a schedule. In a simplified form, it looks like this:
=ARRAYFORMULA({"Teacher Conflicts";IF(COUNTIFS($A4:$A;$A4:$A;B4:B;B4:B)>1;"Conflict";)})
where column A contains time slots and B contains teacher names, like
group 1 Teacher Conflicts
10:00-10:45 Smith Conflict
11:00-11:45 Black
12:00-12:45 Anderson
...
group 2
10:00-10:45 Smith Conflict
11:00-11:45 White
12:00-12:45 Hardy
...
Now, to make it more handy to use, I also use conditional formatting (the whole solution was suggested by MattKing) with formula just =len(C4) to highlight conflicting cells and hide the C column.
As one can see, the second formula is quite simple, so looks like I can move the whole thing into custom formatting like this:
=len(IF(COUNTIFS($A4:$A;$A4:$A;B4:B;B4:B)>1;"Conflict";))
(can be simplified to =COUNTIFS($A4:$A;$A4:$A;B4:B;B4:B)>1, but I just copy-pasted the cell bit to make this clearer; it's not the point here)
The problem is, it doesn't work the same! It highlights different cells. I'm guessing the reason is, in arrayformula and in custom formatting formula, the meaning of the first and the second $A4:$As are different, but I'm not sure how to correct those and how exactly custom formatting formula is read differently. I hope, the expected behavior is clear enough, so the question is, how do I modify the custom formatting formula to get that?
PS here's an MVCE. The formula is a bit more complicated, founds cross-conflicts when the same person is supposed to be a tutor and a teacher at the same time; this actually gives some insights about the source of the problem, compared to simple conflicts. If (in the experiments tab) you try to substitute custom formatting formula =len(D3) with (COUNTIFS($A3:$A;$A3:$A;B3:B;B3:B) + COUNTIFS($A3:$A;$A3:$A;C3:C;B3:B))>1, you'll notice that 2 conflicts are no longer highlighted.
PPS Some more experimenting gave me a hypothesis: looks like the ranges in countifs inside custom formatting formula are not actually B4:B but rather Bn:B where n is the row number of the formatted cell. Not sure how to check this and if it's possible to fix this. Yet.
SUGGESTION
You can try & test this custom formula below that you can add on the Conditional format rules settings.
=countifs($A$4:$A,A4,$B$4:$B,B4) > 1
Sample

Conditional formatting that used to work in Google Sheets, not anymore

A few months back I used to use a conditional formatting to highlight duplicates in a column. The formula I used is: =COUNTIF(A:A, A1)>1.
It doesn't seem to be working anymore. When I try to add this as the custom formula, I get an error message: Invalid formula. I even opened a few older sheets to check, it still works on them. Any tips?
General Grievance's comment:
Change the , to a ;. I think your sheet might be in a different locale.

Google Sheets: Is it possible to simplify this formula? Preferably, I'd like it to calculate all the cells in the row

Can the following formula be simplified as described in the paragraph below it?
=(ABS(D$3-D5)+ABS(E$3-E5)+ABS(F$3-F5)+ABS(G$3-G5)+ABS(H$3-H5)+ABS(I$3-I5)+ABS(J$3-J5)+ABS(K$3-K5))/-1
The problem is that I don't know how many columns I'm going to end up with, and I certainly don't want to continue manually writing each column into the formula. Is there I way to simplify this formula so that every column in a row is calculated?
I've been trying various formulas to no avail, and I can't get usable results via Google searches. I suppose I don't know how to effectively word the question without writing a paragraph.
Thanks, in advance!
Try this one:
=-SUM(ARRAYFORMULA(ABS(D$3:$3 - D5:5)))
GOT IT:
=ArrayFormula(SUM(ABS(D$3:$3-D5:5))/-1)

Conditional Formatting based on sum of the 6 cells below

I was Hoping to be fever along before i had to ask for help but.
using Google sheets i am trying to have a range of cells(a row specificity) change there background colour based on the Sum of the 6 cells directly below it in the
I know I am happy using the basic conditional forming and i have a formula witch will return true if the Sum = what i am looking for
=IF(SUM(D6:D11)=6,true,FALSE())
and this works if i copy and past it along but if i try to put it in the Custom formula is box i get told
There was a problem while
Cannot save the rule with invalid formula.
so i take it that i am not using the box right
any help would be greatly appreciated
Conditional formatting is ... conditional. There is not normally any need for IF(). Your formula should work as:
=Sum(D6:D11)=6
but over what range and what cells to format (other then D5) I can't help you, if required, without further details.
Please though do read the [google-spreadsheet] tag wiki.

Resources