Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35
Default VLookup Value not found ?

I am using the following:

=VLOOKUP($A15,$A$81:$AB$124,Q$1,FALSE)+VLOOKUP($A1 5,$A$126:$AB$160,Q$1,FALSE)

Where $A15 may not exist in either of the arrays or only in one of the two.

How do I allow for this so I get a value rather than the #N/A?

Thanks in advance
--
Jeff C
Live Well .. Be Happy In All You Do
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3,355
Default VLookup Value not found ?

I'm not sure if this will work, but try it

=SUMPRODUCT(--(OFFSET(Sheet1!$A15,0,Sheet1!$Q$1,146,1)=$A$15),(O FFSET(Sheet1!$A15,0,Sheet1!$Q$1,146,1)))

HTH,
Barb Reinhardt



"Jeff C" wrote:

I am using the following:

=VLOOKUP($A15,$A$81:$AB$124,Q$1,FALSE)+VLOOKUP($A1 5,$A$126:$AB$160,Q$1,FALSE)

Where $A15 may not exist in either of the arrays or only in one of the two.

How do I allow for this so I get a value rather than the #N/A?

Thanks in advance
--
Jeff C
Live Well .. Be Happy In All You Do

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default VLookup Value not found ?

You can check each portion to see if it returns an error first:

=if(isna(firstvlookup),0,firstvlookup)
+if(isna(2ndvlookup),0,2ndvlookup)

If you're using xl2007, you could look at =iferror() in excel's help. You won't
have to duplicate each vlookup formula.



Jeff C wrote:

I am using the following:

=VLOOKUP($A15,$A$81:$AB$124,Q$1,FALSE)+VLOOKUP($A1 5,$A$126:$AB$160,Q$1,FALSE)

Where $A15 may not exist in either of the arrays or only in one of the two.

How do I allow for this so I get a value rather than the #N/A?

Thanks in advance
--
Jeff C
Live Well .. Be Happy In All You Do


--

Dave Peterson
  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35
Default VLookup Value not found ?

Thank you both, the ISNA function is what I used successfully, another lesson
learned!
--
Jeff C
Live Well .. Be Happy In All You Do


"Dave Peterson" wrote:

You can check each portion to see if it returns an error first:

=if(isna(firstvlookup),0,firstvlookup)
+if(isna(2ndvlookup),0,2ndvlookup)

If you're using xl2007, you could look at =iferror() in excel's help. You won't
have to duplicate each vlookup formula.



Jeff C wrote:

I am using the following:

=VLOOKUP($A15,$A$81:$AB$124,Q$1,FALSE)+VLOOKUP($A1 5,$A$126:$AB$160,Q$1,FALSE)

Where $A15 may not exist in either of the arrays or only in one of the two.

How do I allow for this so I get a value rather than the #N/A?

Thanks in advance
--
Jeff C
Live Well .. Be Happy In All You Do


--

Dave Peterson

  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 15,768
Default VLookup Value not found ?

Try this:

=SUMIF(A81:A124,A15,INDEX(A81:AB124,,Q1),0)+SUMIF( A126:A160,A15,INDEX(A126:AB160,,Q1),0)

--
Biff
Microsoft Excel MVP


"Jeff C" wrote in message
...
I am using the following:

=VLOOKUP($A15,$A$81:$AB$124,Q$1,FALSE)+VLOOKUP($A1 5,$A$126:$AB$160,Q$1,FALSE)

Where $A15 may not exist in either of the arrays or only in one of the
two.

How do I allow for this so I get a value rather than the #N/A?

Thanks in advance
--
Jeff C
Live Well .. Be Happy In All You Do





  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 15,768
Default VLookup Value not found ?

Ooops!

Typo:

=SUMIF(A81:A124,A15,INDEX(A81:AB124,,Q1),0)+SUMIF( A126:A160,A15,INDEX(A126:AB160,,Q1),0)


Should be:

=SUMIF(A81:A124,A15,INDEX(A81:AB124,,Q1))+SUMIF(A1 26:A160,A15,INDEX(A126:AB160,,Q1))


--
Biff
Microsoft Excel MVP


"T. Valko" wrote in message
...
Try this:

=SUMIF(A81:A124,A15,INDEX(A81:AB124,,Q1),0)+SUMIF( A126:A160,A15,INDEX(A126:AB160,,Q1),0)

--
Biff
Microsoft Excel MVP


"Jeff C" wrote in message
...
I am using the following:

=VLOOKUP($A15,$A$81:$AB$124,Q$1,FALSE)+VLOOKUP($A1 5,$A$126:$AB$160,Q$1,FALSE)

Where $A15 may not exist in either of the arrays or only in one of the
two.

How do I allow for this so I get a value rather than the #N/A?

Thanks in advance
--
Jeff C
Live Well .. Be Happy In All You Do





  #7   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default VLookup Value not found ?

Just a warning...

If the value in A15 occurs multiple times in A81:a124 or multiple times in
A126:A160, then this formula may not return what the original poster needs.




"T. Valko" wrote:

Ooops!

Typo:

=SUMIF(A81:A124,A15,INDEX(A81:AB124,,Q1),0)+SUMIF( A126:A160,A15,INDEX(A126:AB160,,Q1),0)


Should be:

=SUMIF(A81:A124,A15,INDEX(A81:AB124,,Q1))+SUMIF(A1 26:A160,A15,INDEX(A126:AB160,,Q1))

--
Biff
Microsoft Excel MVP

"T. Valko" wrote in message
...
Try this:

=SUMIF(A81:A124,A15,INDEX(A81:AB124,,Q1),0)+SUMIF( A126:A160,A15,INDEX(A126:AB160,,Q1),0)

--
Biff
Microsoft Excel MVP


"Jeff C" wrote in message
...
I am using the following:

=VLOOKUP($A15,$A$81:$AB$124,Q$1,FALSE)+VLOOKUP($A1 5,$A$126:$AB$160,Q$1,FALSE)

Where $A15 may not exist in either of the arrays or only in one of the
two.

How do I allow for this so I get a value rather than the #N/A?

Thanks in advance
--
Jeff C
Live Well .. Be Happy In All You Do




--

Dave Peterson
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, return zero if not found molsansk Excel Worksheet Functions 2 August 22nd 06 06:40 PM
vlookup not found BadgerDave Excel Worksheet Functions 1 April 11th 06 03:29 PM
Vlookup data wrong if the small value found are same Fanny Excel Discussion (Misc queries) 4 January 11th 06 03:05 AM
ISNA VLOOKUP any data prefixed with a "C7" cannot be found? Mike Jenkins Excel Discussion (Misc queries) 6 December 13th 05 02:20 AM
IF NOT FOUND roy.okinawa Excel Worksheet Functions 5 November 17th 05 03:26 AM


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

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

About Us

"It's about Microsoft Excel"