I want to use a VLOOKUP where the second argument (beiing the table_array to examine) is the result of a UDF (user defined function). I can't get this to work because my UDF returns a string and not a range.
My UDF looks like:
Function RANGENAME(namedRANGEinAcell As String) As Range
RANGENAME = namedRANGEinAcell
End Function
The reason why I'm doing this is to avoid the use of the volatile function indirect() in the VLOOKUP.
By substituting
VLOOKUP(lookup_value, indirect(referenced cell with the named range as value);col_index_num)
with
VLOOKUP(lookup_value;RANGENAME(referenced cell with the named range as value);col_index_num)
I figure I do it without the volatility (to be used in 11000 records and over more than 15 columns makes the use of volatile functions a pain in the ***)
Any help would be very much appreciated.
ray:
My UDF looks like:
Function RANGENAME(namedRANGEinAcell As String) As Range
RANGENAME = namedRANGEinAcell
End Function
The reason why I'm doing this is to avoid the use of the volatile function indirect() in the VLOOKUP.
By substituting
VLOOKUP(lookup_value, indirect(referenced cell with the named range as value);col_index_num)
with
VLOOKUP(lookup_value;RANGENAME(referenced cell with the named range as value);col_index_num)
I figure I do it without the volatility (to be used in 11000 records and over more than 15 columns makes the use of volatile functions a pain in the ***)
Any help would be very much appreciated.
ray: