Avatar of ohmetw
ohmetw

asked on 

excel function to sum month columns based, year to date

I have an excel sheet with each month identified in a column (january, February, March, etc..)
I have a 'year to date' calculation column where i would like to only sum up the values in each row, for the previous months of the current year.  

so for example, if for a given row, the January value is 100 and the february value is 400, (and the current month is march) I'd like so logic in the 'year to date' column that will sum the values for the months less than the current month  so..    =SUM(months where < month(today()))

obviously the function above isn't even close to working but am just using to communicate the concept.  I also can't really add any rows above the month column for logic/variables, numbering, etc.  I'd prefer to just use logic rather than manually update each month.  Any help is appreciated!
Microsoft Excel

Avatar of undefined
Last Comment
Rob Henson

8/22/2022 - Mon