Originally Posted by
dyerdyerdyer
if you choose between 'Narrow' and 'Antique' in cell A20 you can see the #REF! results shown. I know they are there because there is only one value in the named range 'Antique' but is there a way they can be removed?
The issue in this instance is that the Named Range being evaluated has fewer rows than being referenced - ie Antique refers only to one row.
Above is 100% accurate - there are a few approaches you could adopt to handle the errors:
a) double evaluate the formula in it's entirety along the lines outlined in prior post (note use of =TRUE is superfluous):
b) double evaluate the INDIRECT element only (ie validate rows)
c) if you know the result is always text you can avoid the double evaluation via a LOOKUP & CHOOSE construct
For the remaining calculations in Col C I would use either
or
If you want to display 0 for the missing items use the latter item and remove the pre-emptive IF
One final pointer...
If your source Defined Names are ever to become Dynamic then INDIRECT will cease to work in the above form
(in other words were "Antique" defined using OFFSET or INDEX construct rather than a hard wired range (such that it resized itself automatically) a basic INDIRECT approach will no longer suffice)
Bookmarks