Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 4
Default Add Totals for Last 12 Months

Hi,
I have monthly totals for several years. Want to keep all totals but only
add the most recent 12 month total. Is there a quick way to do that vs.
revising the formula monthly?

Example:

Cell: A2 B2 C2 D2 E2 F2 G2 H2 I2 J2 K2 L2 M2 N2 O2 P2
#: 1 3 2 1 2 2 1 2 1 3 1 1 2 3 2
2

1st Formula: =SUM(A2:L2)
Next Formula: =SUM(B2:M2)

What's the easy way to shift the 12 cells 1 cell to the right?

Many thanks, in advance, for your help.
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 4,339
Default Add Totals for Last 12 Months

This will give the total of the last 12 months:

=SUM(OFFSET(A2,0,MAX(0,COUNT(2:2)-12),1,12))

OR

in A3 will give A2:L22
=SUM(OFFSET($A$2,0,COLUMN()-1,1,12))

in B3 will give B2:M22
=SUM(OFFSET($A$2,0,COLUMN()-1,1,12))


HTH


"Beamers" wrote:

Hi,
I have monthly totals for several years. Want to keep all totals but only
add the most recent 12 month total. Is there a quick way to do that vs.
revising the formula monthly?

Example:

Cell: A2 B2 C2 D2 E2 F2 G2 H2 I2 J2 K2 L2 M2 N2 O2 P2
#: 1 3 2 1 2 2 1 2 1 3 1 1 2 3 2
2

1st Formula: =SUM(A2:L2)
Next Formula: =SUM(B2:M2)

What's the easy way to shift the 12 cells 1 cell to the right?

Many thanks, in advance, for your help.

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 4
Default Add Totals for Last 12 Months

Toppers,
HUGE thanks for your quick response. The 2 formulas after "OR" worked fine.
Thanks again.

The first one at the top didn't work. It was referring to a circular
reference. I don't know what that means. It was showing 0 in the cell with
the formula.

"Toppers" wrote:

This will give the total of the last 12 months:

=SUM(OFFSET(A2,0,MAX(0,COUNT(2:2)-12),1,12))

OR

in A3 will give A2:L22
=SUM(OFFSET($A$2,0,COLUMN()-1,1,12))

in B3 will give B2:M22
=SUM(OFFSET($A$2,0,COLUMN()-1,1,12))


HTH


"Beamers" wrote:

Hi,
I have monthly totals for several years. Want to keep all totals but only
add the most recent 12 month total. Is there a quick way to do that vs.
revising the formula monthly?

Example:

Cell: A2 B2 C2 D2 E2 F2 G2 H2 I2 J2 K2 L2 M2 N2 O2 P2
#: 1 3 2 1 2 2 1 2 1 3 1 1 2 3 2
2

1st Formula: =SUM(A2:L2)
Next Formula: =SUM(B2:M2)

What's the easy way to shift the 12 cells 1 cell to the right?

Many thanks, in advance, for your help.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Summing Weekly Totals into Monthly Totals steph44haf Excel Worksheet Functions 3 July 5th 06 04:51 PM
How can I subtotal my weekly totals by months? steph44haf Excel Worksheet Functions 1 July 5th 06 03:01 AM
Adding months to dates should account for 28-30-31 day months Graham Excel Worksheet Functions 3 February 1st 06 12:06 PM
Graphing past months (totals) and current month (weekly total) in Davin Charts and Charting in Excel 1 July 27th 05 05:01 PM
How do i change 15 months to read 1 year and 3 months? Marty Excel Discussion (Misc queries) 1 February 17th 05 11:21 PM


All times are GMT +1. The time now is 10:23 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"