Home |
Search |
Today's Posts |
#6
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi
An array formula like that is like a package of individual formulas. These formulas are Row(A1)*(A10) ' returns 1 if A10, else 0 Row(A2)*(A20) ' returns 2 if A30, else 0 Row(A3)*(A30) 'and so on Row(A4)*(A40) .... MAX searches the highest of these results, and SUMPRODUCT wraps it up as an array formula. Then we use this result as month number in a date, and we convert that date to text monthname. I guess you found out already, so just for the archive.... Best wishes Harald "teresa" skrev i melding ... Harald - thats perfect can you explain to me what the function below does - very grateful, I understand each individual function but not working together SUMPRODUCT(MAX(ROW(A1:A12)*(A1:A120))) "Harald Staff" wrote: Hi Try this little thing in A13: =TEXT(DATE(1,SUMPRODUCT(MAX(ROW(A1:A12)*(A1:A120) )),1),"MMM") HTH. Best wishes Harald "teresa" skrev i melding ... If A1 0 AND SUM(A2:A12) = 0 then A13 = Jan If A2 0 AND SUM(A3:A12) = 0 then A13 = Feb If A3 0 AND SUM(A4:A12) = 0 then A13 = March etc.etc. Rather than just using nested Ifs which is cumbersome I am trying: Function Month(Integer) Select Case Integer Case a10,sum(a2:a12)=0 Month = "Jan" etc.... help is much appreciated - thanks |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Creating a Function | Excel Worksheet Functions | |||
Need help creating a function | Excel Discussion (Misc queries) | |||
Creating a Function | Excel Programming | |||
Creating a Sub Function | Excel Programming | |||
Creating a function | Excel Programming |