Question on using "IF", "AND", & "SUM" functions together.

I am trying to create a semi-complex formula. I have two check boxes. When someone clicks check box "A", it sums up specific columns. When someone clicks check box "B", it sums up the other columns. When someone clicks both "A" and "B" check boxes, it'll sum up all of the columns. I was able to get the individual parts working, but not when someone clicks both "A" and "B" columns.
Here is the formula I have set up: (I've edited the column slightly to use more neutral terms):
=IF(AND([Box A]@row = "true", [Box B]@row = "true"), =SUM(Column3:Column11), "false")
I am able to get the individual parts working, but I am getting an #invalidoperations when putting it all together.
For example, if I replace the sum function with ' "true" ' or something simple instead, the sheet is able to read when I have both columns clicked, and therefore will spit out "true." But when the sum formula is in place, it spits out #Invalidoperations.
Could someone help explain why this might be the case? I've already double checked to make sure all the columns are reading as numbers and not text.
Best Answer
-
You have a second = in your formula try
=IF(AND([Box A]@row = "true", [Box B]@row = "true"), SUM(Column3:Column11), "false")
Answers
-
You have a second = in your formula try
=IF(AND([Box A]@row = "true", [Box B]@row = "true"), SUM(Column3:Column11), "false")
-
@Hollie Green Ha. That worked! Thank you so much!!
Help Article Resources
Categories
Check out the Formula Handbook template!