Link to home
Start Free TrialLog in
Avatar of route217
route217Flag for United Kingdom of Great Britain and Northern Ireland

asked on

formula to sum columns based a value in a given column

Hi Experts (excel 2007)

I need a sum formula to sum across the data in a set number of columns based on what number i enter in column U

So if i enter in column u 4 then >

starting at column 6C (always) sum columns 6C:6F and enter result in column P

So if i enter in Column u 7 then>

Staring at column 6C (always) sum Columns 6C:6I etc....
Avatar of [ fanpages ]
[ fanpages ]

Hi,

Sorry, how does a value of 4 (or 7) relate to the specific starting columns/rows you have stated?

Also, where is 4 entered in column U?  Which row?

BFN,

fp.
Avatar of route217

ASKER

apologies fp

Assume 4 is entered in row 7 column U

and then we want to sum up the data in column C7:F7...
ASKER CERTIFIED SOLUTION
Avatar of [ fanpages ]
[ fanpages ]

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
thanks for the feedack fp
You're welcome.
Hi,

To be able to use the formula in different rows
pls use

=SUM(INDIRECT("R"&ROW(P6)&"C"&3&":"&"R"&ROW(P6)&"C"&2+P6,FALSE))

Regards
...or, place this formula in cell [U7]:
=SUM(INDIRECT(ADDRESS(ROW(),3)&":"&ADDRESS(ROW(),3+U7-1)))

...and copy down column [ U ] to any other row.
Q-28244877b.xls