Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

add up repeating values in two columns

Status
Not open for further replies.

thelos

Technical User
Aug 1, 2005
17
GB
hi guys

i had a question on consolidation yesterday its along the same lines .

if i have two columns the date and value of hours is it possible to loop through them adding up the values if the dates are the same leaving me with one date and one value i tried using the pivot

info i have product i want
column a column b column a column b
date hours date hours
17/08/05 7 17/08/05 10
17/08/05 3 13/03/05 4
13/03/05 2
13/03/05 2
 
I just used pivottable, and it did exactly what you want. What did it do when you tried it?

Cheers, Glenn.

Did you hear about the literalist show-jumper? He broke his nose jumping against the clock.
 
i have the results linked to a graph so i have to give coordinates for the graph to read from a consolidation works best but trying to code it for a macro to work on different machines was a bit strange thats why im looking for a chunk of code that just cycles through adding up hours for repeating dates would work alot better
 
whether you use code to loop or a pivottable, you're still going to have to change the chart plot range

I would still use a pvottable as per yesterday - unless you have some other info that you havn't shared, my opinion hasn't changed

Rgds, Geoff

Three things are certain. Death, taxes and lost data. DPlank is to blame

Please read FAQ222-2244 before you ask a question
 
Have you ever thought of finding out about punctuation???? ( you're posting is a real headache without it )

It sounds like you want to be complicated due to needing a graph. Why not use a PivotChart?



Cheers, Glenn.

Did you hear about the literalist show-jumper? He broke his nose jumping against the clock.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top