add If to formula to blank #n/a

D

Diddy

Hi everyone,

I'm using the following formula

=INDEX(Stats!$K$2:$K$47,MATCH($B3,Stats!$G$2:$G$47,0))

How do I add to this to not have #N/A when it doesn't find a match?

Thank you!
 
M

Max

Just add an IF(ISNA(..) error trap on the MATCH part of it, eg
=IF(ISNA(MATCH($B3,Stats!$G$2:$G$47,0)),"",INDEX(Stats!$K$2:$K$47,MATCH($B3,Stats!$G$2:$G$47,0)))

Adapt the return: "" to suit what you want for unmatched cases
--
Max
Singapore
http://savefile.com/projects/236895
Downloads:17,500 Files:358 Subscribers:55
xdemechanik
 
D

Diddy

Thank you Max :)
--
Deirdre


Max said:
Just add an IF(ISNA(..) error trap on the MATCH part of it, eg:
=IF(ISNA(MATCH($B3,Stats!$G$2:$G$47,0)),"",INDEX(Stats!$K$2:$K$47,MATCH($B3,Stats!$G$2:$G$47,0)))

Adapt the return: "" to suit what you want for unmatched cases
--
Max
Singapore
http://savefile.com/projects/236895
Downloads:17,500 Files:358 Subscribers:55
xdemechanik
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top