#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 5
Default VLOOKUP


Hi,

As you know, when VLOOKUP uses "FALSE" for Range_lookup and no exact match
is made, Excel produces an output "#N/A".

This is messing up formulae that are based on the output of cells where this
formula is used, where then produce the same "#N/A".

I have tried using an If function in conjunction with VLOOKUP but it did not
produce the desired effect. Can someone please tell me if this is possible
(and I have made a mistake) or is there some other way.

Thanks in advance for any feedback.

Sam

--
Sam H. Carson
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 4,624
Default VLOOKUP

Before one can tell you what is possible with something other than an
(unspecified) IF() function, it's necessary for you to actually say what
"the desired effect" is...

You can return a null string, e.g.:

=IF(ISNA(MATCH(A1,J:J,FALSE)),"", VLOOKUP(A1,J:K,2,FALSE))

or you can change "" to 0 if you need a zero value, etc.

In article ,
Sam H. Carson wrote:

Hi,

As you know, when VLOOKUP uses "FALSE" for Range_lookup and no exact match
is made, Excel produces an output "#N/A".

This is messing up formulae that are based on the output of cells where this
formula is used, where then produce the same "#N/A".

I have tried using an If function in conjunction with VLOOKUP but it did not
produce the desired effect. Can someone please tell me if this is possible
(and I have made a mistake) or is there some other way.

Thanks in advance for any feedback.

Sam

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 964
Default VLOOKUP

The IF statement should look something like this:

=IF(ISNA(VLOOKUP(...)),0,VLOOKUP(...))

This states that if your VLOOKUP formula returns the #N/A error, then return
a 0, if not, then return the results of your VLOOKUP formula. You could
replace the 0 with "" depending what you want in place of the #N/A error.

HTH,
Elkar


"Sam H. Carson" wrote:


Hi,

As you know, when VLOOKUP uses "FALSE" for Range_lookup and no exact match
is made, Excel produces an output "#N/A".

This is messing up formulae that are based on the output of cells where this
formula is used, where then produce the same "#N/A".

I have tried using an If function in conjunction with VLOOKUP but it did not
produce the desired effect. Can someone please tell me if this is possible
(and I have made a mistake) or is there some other way.

Thanks in advance for any feedback.

Sam

--
Sam H. Carson

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 5
Default VLOOKUP


Thanks Elkar, that's perfect! Exactly what I was looking for.

Much appreciated.

--
Sam H. Carson


"Elkar" wrote:

The IF statement should look something like this:

=IF(ISNA(VLOOKUP(...)),0,VLOOKUP(...))

This states that if your VLOOKUP formula returns the #N/A error, then return
a 0, if not, then return the results of your VLOOKUP formula. You could
replace the 0 with "" depending what you want in place of the #N/A error.

HTH,
Elkar


"Sam H. Carson" wrote:


Hi,

As you know, when VLOOKUP uses "FALSE" for Range_lookup and no exact match
is made, Excel produces an output "#N/A".

This is messing up formulae that are based on the output of cells where this
formula is used, where then produce the same "#N/A".

I have tried using an If function in conjunction with VLOOKUP but it did not
produce the desired effect. Can someone please tell me if this is possible
(and I have made a mistake) or is there some other way.

Thanks in advance for any feedback.

Sam

--
Sam H. Carson

  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 5
Default VLOOKUP


Thanks JE. It will never cease to amaze me where you guys get this code from!

--
Sam H. Carson


"JE McGimpsey" wrote:

Before one can tell you what is possible with something other than an
(unspecified) IF() function, it's necessary for you to actually say what
"the desired effect" is...

You can return a null string, e.g.:

=IF(ISNA(MATCH(A1,J:J,FALSE)),"", VLOOKUP(A1,J:K,2,FALSE))

or you can change "" to 0 if you need a zero value, etc.

In article ,
Sam H. Carson wrote:

Hi,

As you know, when VLOOKUP uses "FALSE" for Range_lookup and no exact match
is made, Excel produces an output "#N/A".

This is messing up formulae that are based on the output of cells where this
formula is used, where then produce the same "#N/A".

I have tried using an If function in conjunction with VLOOKUP but it did not
produce the desired effect. Can someone please tell me if this is possible
(and I have made a mistake) or is there some other way.

Thanks in advance for any feedback.

Sam


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Vlookup in vlookup - taking the result as array name SupperDuck Excel Worksheet Functions 2 June 2nd 07 11:05 AM
Combine VLOOKUP and IF function so #NA isn't returned as a value from VLOOKUP buffgirl71 Excel Discussion (Misc queries) 12 November 14th 06 11:36 PM
Vlookup -=VLOOKUP(F9,LookUp1!$A$2:$B$1504,2,FALSE) MikeR-Oz New Users to Excel 1 March 22nd 06 09:01 AM
IF(AND(val1=VLOOKUP( );val2>=VLOOKUP( );val2<=VLOOKUP( );VLOOKUP( Oso Excel Worksheet Functions 2 January 26th 05 06:56 AM
Vlookup info being used without vlookup table attached? Excel Worksheet Functions 0 January 25th 05 10:43 AM


All times are GMT +1. The time now is 11:46 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"