View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Dave Peterson[_2_] Dave Peterson[_2_] is offline
external usenet poster
 
Posts: 420
Default How to implement mySum(Sheet1:Sheet3!B1)?

Take a look at what you'll need to do at John Walkenbach's old site:

http://j-walk.com/ss/excel/eee/eee003.txt
and look for SumProduct3D, SumIf3D, CountIf3D
By Myrna Larson and David Hager



On 12/26/2010 22:39, joeu2004 wrote:
I can call SUM(Sheet1:Sheet3!B1) in A1.

But I cannot call mySum(Sheet1:Sheet3!B1).

What type of object is passed for that kind of range?

Why doesn't the following work? The second MsgBox displays Error.

Function mySum(ParamArray x())
MsgBox LBound(x)& " "& UBound(x)
MsgBox TypeName(x(0))
End Function


--
Dave Peterson