#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1
Default Sum and Count


HI,

I am trying to write a formula to read various columns and count up the
total time.

Data below please align in rows and columns
A B C D ---------What i need the formular to read is, if
(a1:a5=0,and if b1:b5=0
1 1 1 0:20 ----------then total c1:c5) the answer should be 0:40
2 0 1 0:20
3 0 0 0:20
4 1 1 0:20
5 0 0 0:20

Thanks
Brento


--
Brento
------------------------------------------------------------------------
Brento's Profile: http://www.excelforum.com/member.php...o&userid=25213
View this thread: http://www.excelforum.com/showthread...hreadid=570886

  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1
Default Sum and Count


Brento,

Try,

=SUMPRODUCT((A1:A5=0)*(B1:B5=0)*(C1:C5))

Format the result as h:mm.

HTH

Steve


--
SteveG
------------------------------------------------------------------------
SteveG's Profile: http://www.excelforum.com/member.php...fo&userid=7571
View this thread: http://www.excelforum.com/showthread...hreadid=570886

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,574
Default Sum and Count

if(and(count(a1:a5)=0,count(b1:b5)=0,sum(c1:c5),"" )

(Note the "" is the ELSE clause of the IF statement, since you didn't
specify an ELSE requirement....)

This is also assuming that by a1:a5=0 you mean its count, and not its sum,
is 0. If it's sum you're referring to then replace count with sum in the
formula above.

Dave

"Brento" wrote:


HI,

I am trying to write a formula to read various columns and count up the
total time.

Data below please align in rows and columns
A B C D ---------What i need the formular to read is, if
(a1:a5=0,and if b1:b5=0
1 1 1 0:20 ----------then total c1:c5) the answer should be 0:40
2 0 1 0:20
3 0 0 0:20
4 1 1 0:20
5 0 0 0:20

Thanks
Brento


--
Brento
------------------------------------------------------------------------
Brento's Profile: http://www.excelforum.com/member.php...o&userid=25213
View this thread: http://www.excelforum.com/showthread...hreadid=570886


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



All times are GMT +1. The time now is 12:19 PM.

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"