Sum every other column - offset function?

caststone

New Member
Joined
Feb 3, 2015
Messages
17

Excel 2010
ABCDEFGHIJK
1week nodaysweek nodaysweek nodaysweek nodaysweek nodays
20
Sheet1

In the simplified table above I am looking to sum all the values in the blue cells(every other column) and show the resulting value in the red cell.

It would seem as simple as =sum(C2+E2+G2+I2+K2)

However the problem I have is that each week I insert a new pair of columns after column A. This means that the formula above allows for the column insertion and changes to =SUM(E2+G2+I2+K2+M2).

I have tried using absolute column references =sum($C2+$E2+$G2+$I2+$K2) but this has no effect.

I have looked at the offset function which seems at least to address the issue of the formula changing as columns are inserted but I cannot understand how to make this work for my particular example.

Any help gratefully received.
 
Good point - I will add a comment to my spreadsheet to that effect so I don't make that mistake. Thank you again.
 
Upvote 0

Excel Facts

Fastest way to copy a worksheet?
Hold down the Ctrl key while dragging tab for Sheet1 to the right. Excel will make a copy of the worksheet.
perhaps something like this

=IF($A$1="Days","Remove Days from A1",SUMIF($A$1:$CZ$1,"Days",$A2:$CZ2))
 
Upvote 0
Indirect requires a text string that refers to a range of cells or a single cell. As it's text it is ignored by dragging/ inserting. It returns the cell references referred to in the text string. It is a volatile function so excel recalculates it each and every time any cell is calculated regardless if the calculated cell is in the 'dependency tree' so can make workbooks slow.
 
Upvote 0
Hi Steve - word 'Volatile' scares me so will go with Jonmo1' answer but thank you very much for taking the time to explain it.

and

Jonmo1 - that's an easy way to avoid sending the spreadsheet into a spin :), thank you very much.
 
Upvote 0

Forum statistics

Threads
1,216,100
Messages
6,128,834
Members
449,471
Latest member
lachbee

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?

Disable AdBlock

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
Back
Top