View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.misc
Max Max is offline
external usenet poster
 
Posts: 9,221
Default SUM up diferences with a criteria

Another way ..

Try in say, B1:
=SUMPRODUCT(--(A2:A5-A1:A40),A2:A5-A1:A4)*1000
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"Nuno" wrote:
Hi there,
I'm having a problem with someting I need to do. I need to SUM up diferences
with a criteria!! For example:
A B
1 1.544 -322 (A2-A1)
2 1.222 0 (A3-A2)
3 1.222 541 (A4-A5)
4 1.763 37 (A5-A4)
5 1.800 -563 ..........

Total needed = is the sum of positive differences 541+37 = 578
I would like to know if there is a formula which gives me this result (578)
without using the collumn B ??

Can you help me? thanks.
Brgds
Nuno