ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   How do I pull data for consecutive months in an Excel spreadsheet (https://www.excelbanter.com/excel-worksheet-functions/193342-how-do-i-pull-data-consecutive-months-excel-spreadsheet.html)

Patti Ayala[_2_]

How do I pull data for consecutive months in an Excel spreadsheet
 
Every month I have to add the next consecutive month's data to my formulas in
an Excel spreadsheet. For instance, in March 2008 I need to include YTD
sales comparison data from a work sheet that has 2007 monthly sales, so my
formulas pull from the January, February and March 2007 cells. When I move
on to April 2008, I have to go back and manually change my formulas to add
the cells that include April 2007 sales data. Is there any way to set this
up so I don't have to make these changes manually every month?

Glenn

How do I pull data for consecutive months in an Excel spreadsheet
 
Patti Ayala wrote:
Every month I have to add the next consecutive month's data to my formulas in
an Excel spreadsheet. For instance, in March 2008 I need to include YTD
sales comparison data from a work sheet that has 2007 monthly sales, so my
formulas pull from the January, February and March 2007 cells. When I move
on to April 2008, I have to go back and manually change my formulas to add
the cells that include April 2007 sales data. Is there any way to set this
up so I don't have to make these changes manually every month?



I'm sure there is, but it would help if you would show what your data and
formula looks like now.

Spiky

How do I pull data for consecutive months in an Excel spreadsheet
 
Assuming your data starts in B2 and goes sideways, this can be in
whichever column you want, D2, H2, etc:

=SUM(B2:OFFSET(B2,,,,COLUMN()-COLUMN(B2)))

And it should work as you add columns, even if they are right next to
this SUM.


All times are GMT +1. The time now is 08:08 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com