Vlook problems

  • Thread starter Thread starter Mark h
  • Start date Start date
M

Mark h

Hi ,
I have this formulae
=IF(VLOOKUP($A6,RPD_Switch_Report_20030113!
$A$4:$M$1500,12,0)="#N/A","not found",VLOOKUP
($A6,RPD_Switch_Report_20030113!$A$4:$M$1500,12,FALSE))

What I am trying to do is if the data in column A is not
found in the table then return a Not Found statement. If
it is found then return the value.

The value is returned without problems but I cannot get
the "not found stmt to work" I just get the #n/a in the
cell.

Thanks
Mark
 
Mark

XL provides error functions for this ISERROR, ISNA, ISERR, Etc. If you are
just looking to trap the #N/A error, you could use ISNA, because that's all
it traps. I normally use ISERROR, as it traps all. ISERR traps all but
#N/A. You get the drift!

Your formula would be. (formula not checked for accuracy, simply pasted from
example)

=IF(ISERROR(VLOOKUP($A6,RPD_Switch_Report_20030113!$A$4:$M$1500,12,0)),"not
found",VLOOKUP($A6,RPD_Switch_Report_20030113!$A$4:$M$1500,12,0))
 
Mark,

Try this.


=IF(ISNA(VLOOKUP($A6,RPD_Switch_Report_20030113!$A$4:$M$1500,12,0)),"not
found",VLOOKUP($A6,RPD_Switch_Report_20030113!$A$4:$M$1500,12,FALSE))

HTH
Paul
 
Back
Top