M
MH UK
I have a vlookup formula, but want to programatically change the range the
look up looks at.
The data set is filtered by vba by user selection from a drop down list
If I want to change
=IF(S4="","",VLOOKUP(S4,MFData!$D$2:$S$4000,16,FALSE))
to the same range as is filtered.
In one scenario the data range is filtered to rows 2008 to 2243 (rather than
2 to 4000), how can I change the formula to
=IF(S4="","",VLOOKUP(S4,MFData!$D$2008:$S$2243,16,FALSE))
Presumably by defining a named range each time the filter is applied.
Thanks in anticipation
look up looks at.
The data set is filtered by vba by user selection from a drop down list
If I want to change
=IF(S4="","",VLOOKUP(S4,MFData!$D$2:$S$4000,16,FALSE))
to the same range as is filtered.
In one scenario the data range is filtered to rows 2008 to 2243 (rather than
2 to 4000), how can I change the formula to
=IF(S4="","",VLOOKUP(S4,MFData!$D$2008:$S$2243,16,FALSE))
Presumably by defining a named range each time the filter is applied.
Thanks in anticipation