LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 15
Default SumProduct problem

Hello,

I wrote a function which is using SumProduct.

a is a worksheet range
b is a worksheet cell
c is a worksheet range

Function cond_average(a, b, c)

If Application.SumProduct(--(a = b), --(c < "")) = 0 Then
cond_average = -1
Else
cond_average = Application.SumIf(a, b, c) / Application.CountIf(a,
b)
End If

End Function

Sumif and CountIf functions works but SumProduct returns error.

What is wrong ?

thank you
Gil D.

 
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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem with SUMPRODUCT Sasikiran Excel Discussion (Misc queries) 5 June 29th 09 09:22 AM
SUMPRODUCT #VALUE! problem Vibeke Excel Worksheet Functions 4 March 18th 07 04:46 AM
Problem with SumProduct dinadvani via OfficeKB.com Excel Discussion (Misc queries) 5 July 31st 06 01:55 PM
Problem using sumproduct Hiughs Excel Worksheet Functions 4 March 5th 05 11:28 AM
SUMPRODUCT Problem Mestrella31 Excel Discussion (Misc queries) 2 December 21st 04 07:01 PM


All times are GMT +1. The time now is 09:00 AM.

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"