# Getting a total for everyother row

#### RedSoxHugh

##### New Member
I'm new at this, how do I get a total at the bottom for everyother row?

### Excel Facts

How to total the visible cells?
From the first blank cell below a filtered data set, press Alt+=. Instead of SUM, you will get SUBTOTAL(9,)
Odd rows or Even rows ?

both, someone sent me a spreadsheet with number of accounts and then dollars for account under. I need totals for both.

maybe just

=SUM(A1,A3,A5,A7 ) etc and
=SUM(A2,A4,A6,A8) etc.

Pekka

tried that, I get an error because there are too many cells, the report is 70 lines long. Is there a formula that recognizes grabbing evens or odds in general?

RedSoxHugh said:
I'm new at this, how do I get a total at the bottom for everyother row?

1.

=SUMPRODUCT(--(MOD(ROW(A3:A8)-ROW(A3)+0,2)=0),A3:A8)

2.

=SUMPRODUCT(--(MOD(ROW(A3:A8)-ROW(A3)+1,2)=0),A3:A8)

You could use an extra column
Put there
1
2
1
2
1
2
1

Etc.
Then use
=SUMIF(B1:B70,1,A1:A70) and
=SUMIF(B1:B70,2,A1:A70)

Pekka

Try these:

For even rows: =SUM(IF(MOD(ROW(A1:A100),2)=0,A1:A100))

For odd rows: =SUM(IF(MOD(ROW(A1:A100),2)=1,A1:A100))

Formulas must be confirmed with Ctrl+Shift+Enter, not just Enter.

Adjust ranges to suit.

try something like this
Book1
ABCD
17050-11
21000
37050-21
41000
57050-41
61000
77050-11
87050-20
91001
107050-40
111001
127050-10
131001
147050-20
151001
167050-40
171001
18300
Sheet1

HTH

NBVC said:
Try these:

For even rows: =SUM(IF(MOD(ROW(A1:A100),2)=0,A1:A100))

For odd rows: =SUM(IF(MOD(ROW(A1:A100),2)=1,A1:A100))

Formulas must be confirmed with Ctrl+Shift+Enter, not just Enter.

Adjust ranges to suit.

Insert a row before the current row 1...

Replies
8
Views
221
Replies
1
Views
57
Replies
10
Views
226
Replies
1
Views
44
Replies
2
Views
108

1,212,138
Messages
6,106,173
Members
448,003
Latest member
ZdenekP

### We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

### Which adblocker are you using?

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

### Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

### Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

### Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back