ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   add If to formula to blank #n/a (https://www.excelbanter.com/excel-worksheet-functions/200570-add-if-formula-blank-n.html)

Diddy

add If to formula to blank #n/a
 
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!
--
Deirdre

Max

add If to formula to blank #n/a
 
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(S tats!$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
---
"Diddy" wrote:
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!
--
Deirdre


Diddy

add If to formula to blank #n/a
 
Thank you Max :-)
--
Deirdre


"Max" wrote:

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(S tats!$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
---
"Diddy" wrote:
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!
--
Deirdre


Max

add If to formula to blank #n/a
 
Welcome, Deirdre
--
Max
Singapore
http://savefile.com/projects/236895
Downloads:17,500, Files:358, Subscribers:55
xdemechanik
---
"Diddy" wrote in message
...
Thank you Max :-)
--
Deirdre





All times are GMT +1. The time now is 03:58 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com