Posted by Brian P. on June 27, 2000 8:10 AM
I'm tring to build a UDF that will return True/False if the cells in range meet the condition, but it does not work for the range, it works only for individual cells. Any help greatly appreciated.
My case: B1=33; B2=4; B3=22; B4=333. In B8 I have the UD function: =myNumber(B1:B4) and the result is True instead of False because not all numbers in B1:B4>10.
This is the code:
Function myNUMBER(MYRANGE As Range) As Boolean
For Each CELL In MYRANGE.Cells
If CELL.Value > 10 Then
myNUMBER = True
Else: myNUMBER = False