Here is the situation I'm having in a Google spreadsheet:
I need to sum up every second cell in the yellow line (look at the picture) not including those ones which are below the statement FALSE
in the red line. Those statements are written in two merged cells if it has any importance in solving this problem. In this example, the right numbers should be: 4.00
, 4.00
, 8.00
with 16.00
as a final answer.
I did some research in various Excel forums and found out this line should do the trick for summing up every second cell in a single column beginning with B3
cell:
= SUM(IF(MOD(ROW($B$3:$B$22) - ROW($B$3) + 1, 2) = 0, $B$3:B$22, 0))
I adjusted this to my situation (for the moment ignoring the fact about TRUE-FALSE check):
= SUM(IF(MOD(COLUMN($E$6:$N$6) - COLUMN($E$6) + 1, 2)=0, $E$6:N$6, 0))
Unfortunately, it is not working for me in a Google spreadsheet. Finally, I came up with formula which is working corectly for this purpose:
= SUM(IF($E$2 = "TRUE", $F6, 0), IF($G$2 = "TRUE", $H6, 0), IF($I$2 = "TRUE", $J6, 0), IF($K$2 = "TRUE", $L6, 0), IF($M$2 = "TRUE", $N6, 0))
The problem is that constructing the formula this way is going to make it extremely long and way too inconvenient (as hundreds of columns are going to be added on the left)
Any suggestions?