How to get rid/hide #NUM! error in Excel 2003?
Guntars wrote...
This is the array formula which works in Excel 2007:
=IFERROR(TRANSPOSE(INDEX(Employees!A2:BN4,1,
SMALL(IF(Employees!F4:BN4="5S",COLUMN(Employees!F 4:BN4)),
COLUMN(1:1)))+37),"")
....
I can't see any point to the TRANSPOSE call. The INDEX call inside it
returns a single number, so TRANSPOSE does nothing. Best to remove it.
The #NUM! error would occur when the SMALL call's 2nd argument exceeds
the number of entries in its 1st argument. That could be trapped more
elegantly as
=IF(COUNTIF(Employees!F4:BN4,"5S")=COLUMN(1:1),IN DEX(Employees!
A2:BN4,1,
SMALL(IF(Employees!F4:BN4="5S",COLUMN(Employees!F4 :BN4)),COLUMN(1:1)))
+37,"")
which would be exactly the same in Excel 2007 and Excel 2003.
Furthermore, it'd propagate errors from Employees!F4:BN4 (if any),
which is usually a good thing.
|