Sum Left to Right

Pestomania

Active Member
Joined
May 30, 2018
Messages
292
Office Version
  1. 365
Platform
  1. Windows
I am using SumProduct to identify the row that I want to get values from and the columns to create a "right" limit. Now I want to add everything from left to right and drag it left to get the value change.

I am going to try and show what I have below:

Table 1
ProgramOperation 1Operation 2Operation 3Operation 4Operation 5Total Days
Program Name 151012182570
Program Name 23914151859

Table 2
ProgramOperation 1Operation 2Operation 3Operation 4Operation 5Total Days
Program Name 1Total Days = 70Total Days - Sum(Operation 1:Operation 1) = 65Total Days - Sum(Operation 1:Operation 2) = 55
Total Days - Sum(Operation 1: Operation 3) = 43
Total Days - Sum(Operation 1:Operation 4) = 2570
Program Name 2Total Days = 59Total Days - Sum(Operation 1:Operation 1) = 56Total Days - Sum(Operation 1:Operation 2) = 47
Total Days - Sum(Operation 1: Operation 3) = 33
Total Days - Sum(Operation 1:Operation 4) = 1859

I want to make table 2 update if I change Table 1.

I have been using sumproduct to find my Total Days, but I cannot figure out how to do the dynamic ranger for Operation #'s.

Thank you!
 

Excel Facts

What did Pito Salas invent?
Pito Salas, working for Lotus, popularized what would become to be pivot tables. It was released as Lotus Improv in 1989.
like this?

Book1
ABCDEFG
1Table 1
2ProgramOperation 1Operation 2Operation 3Operation 4Operation 5Total Days
3Program Name 151012182570
4Program Name 23914151859
5
6Table 2
7ProgramOperation 1Operation 2Operation 3Operation 4Operation 5Total Days
8Program Name 1706555432570
9Program Name 2595647331859
Sheet2
Cell Formulas
RangeFormula
B8:B9B8=G3
C8:F8C8=B8-SUM(B$3:B3)
C9:F9C9=B9-SUM(B$4:B4)
 
Upvote 0
Hi,

Not sure to understand your question ...
May be in cell G2 =SUM(F2:OFFSET(F2,0,-4))
-4 does indicate how many columns to the Left ...
 
Upvote 0
like this?

Book1
ABCDEFG
1Table 1
2ProgramOperation 1Operation 2Operation 3Operation 4Operation 5Total Days
3Program Name 151012182570
4Program Name 23914151859
5
6Table 2
7ProgramOperation 1Operation 2Operation 3Operation 4Operation 5Total Days
8Program Name 1706555432570
9Program Name 2595647331859
Sheet2
Cell Formulas
RangeFormula
B8:B9B8=G3
C8:F8C8=B8-SUM(B$3:B3)
C9:F9C9=B9-SUM(B$4:B4)
Yes in simple terms that is how it would work but I want it in a dynamic version similar to sumproduct so that it can maintain dynamic as I may add programs to the table and I want it to update.
 
Upvote 0

Forum statistics

Threads
1,214,957
Messages
6,122,466
Members
449,086
Latest member
kwindels

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