Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 7
Default IF VLOOKUP Nested function

I have a formula that returns a lookup value
=VLOOKUP(A10,VarietyLookUpTable!$A$2:$C$56,2,FALSE )
but when I try to make it so that there is no value in the cell if the
reference cell is blank
=IF(A12,VLOOKUP(A12,VarietyLookUpTable!$A$2:$C$56, 2,FALSE),"")
It only works if the cell is blank, if there is a value in the cell which is
formatted as text I get the #VALUE! instead of the usual result
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,574
Default IF VLOOKUP Nested function

Use this syntax:

=IF(ISERROR(VLOOKUP([your criteria])),"",VLOOKUP([your criteria]))

"IF the VLOOKUP returns an error, THEN blank, ELSE do the VLOOKUP"

Dave
--
Brevity is the soul of wit.


"Paul LeBlanc" wrote:

I have a formula that returns a lookup value
=VLOOKUP(A10,VarietyLookUpTable!$A$2:$C$56,2,FALSE )
but when I try to make it so that there is no value in the cell if the
reference cell is blank
=IF(A12,VLOOKUP(A12,VarietyLookUpTable!$A$2:$C$56, 2,FALSE),"")
It only works if the cell is blank, if there is a value in the cell which is
formatted as text I get the #VALUE! instead of the usual result

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 4,393
Default IF VLOOKUP Nested function

The formula =IF(A1,1,0) returns 0 when A1 is blank because a blank is
treated as ) and zero is treated as FALSE. It returns 1 if A1 has a numeric
value because an number is treated as TRUE
But it returns #VALUE! if A1 has text because the first argument is not a
Boolean value.
Try IF(ISBLANK(A12), "", VLOOKUP.........)
But recall that if A12 has a formula that returns a null string ("") it will
not pass the ISBLANK test; the cell must be truly empty.
best wishes

--
Bernard V Liengme
www.stfx.ca/people/bliengme
remove caps from email

"Paul LeBlanc" wrote in message
...
I have a formula that returns a lookup value
=VLOOKUP(A10,VarietyLookUpTable!$A$2:$C$56,2,FALSE )
but when I try to make it so that there is no value in the cell if the
reference cell is blank
=IF(A12,VLOOKUP(A12,VarietyLookUpTable!$A$2:$C$56, 2,FALSE),"")
It only works if the cell is blank, if there is a value in the cell which
is
formatted as text I get the #VALUE! instead of the usual result



  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 7
Default IF VLOOKUP Nested function

Excel says there are too many arguments
=IF(ISERROR,(VLOOKUP(A12,VarietyLookUpTable!$A$2:$ C$56,2,FALSE)),"",VLOOKUP(A12,VarietyLookUpTable!$ A$2:$C$56,2,FALSE))

"Dave F" wrote:

Use this syntax:

=IF(ISERROR(VLOOKUP([your criteria])),"",VLOOKUP([your criteria]))

"IF the VLOOKUP returns an error, THEN blank, ELSE do the VLOOKUP"

Dave
--
Brevity is the soul of wit.


"Paul LeBlanc" wrote:

I have a formula that returns a lookup value
=VLOOKUP(A10,VarietyLookUpTable!$A$2:$C$56,2,FALSE )
but when I try to make it so that there is no value in the cell if the
reference cell is blank
=IF(A12,VLOOKUP(A12,VarietyLookUpTable!$A$2:$C$56, 2,FALSE),"")
It only works if the cell is blank, if there is a value in the cell which is
formatted as text I get the #VALUE! instead of the usual result

  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,574
Default IF VLOOKUP Nested function

There are too many arguments because you have a comma between ISERROR and
VLOOKUP. Try this:

=IF(ISERROR(VLOOKUP(A12,VarietyLookUpTable!$A$2:$C $56,2,FALSE)),"",VLOOKUP(A12,VarietyLookUpTable!$A $2:$C$56,2,FALSE))

Dave
--
Brevity is the soul of wit.


"Paul LeBlanc" wrote:

Excel says there are too many arguments
=IF(ISERROR,(VLOOKUP(A12,VarietyLookUpTable!$A$2:$ C$56,2,FALSE)),"",VLOOKUP(A12,VarietyLookUpTable!$ A$2:$C$56,2,FALSE))

"Dave F" wrote:

Use this syntax:

=IF(ISERROR(VLOOKUP([your criteria])),"",VLOOKUP([your criteria]))

"IF the VLOOKUP returns an error, THEN blank, ELSE do the VLOOKUP"

Dave
--
Brevity is the soul of wit.


"Paul LeBlanc" wrote:

I have a formula that returns a lookup value
=VLOOKUP(A10,VarietyLookUpTable!$A$2:$C$56,2,FALSE )
but when I try to make it so that there is no value in the cell if the
reference cell is blank
=IF(A12,VLOOKUP(A12,VarietyLookUpTable!$A$2:$C$56, 2,FALSE),"")
It only works if the cell is blank, if there is a value in the cell which is
formatted as text I get the #VALUE! instead of the usual result



  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 7
Default IF VLOOKUP Nested function

Thanks, I worked on getting all the parenthesis right but missed that sneaky
little comma

"Dave F" wrote:

There are too many arguments because you have a comma between ISERROR and
VLOOKUP. Try this:

=IF(ISERROR(VLOOKUP(A12,VarietyLookUpTable!$A$2:$C $56,2,FALSE)),"",VLOOKUP(A12,VarietyLookUpTable!$A $2:$C$56,2,FALSE))

Dave
--
Brevity is the soul of wit.


"Paul LeBlanc" wrote:

Excel says there are too many arguments
=IF(ISERROR,(VLOOKUP(A12,VarietyLookUpTable!$A$2:$ C$56,2,FALSE)),"",VLOOKUP(A12,VarietyLookUpTable!$ A$2:$C$56,2,FALSE))

"Dave F" wrote:

Use this syntax:

=IF(ISERROR(VLOOKUP([your criteria])),"",VLOOKUP([your criteria]))

"IF the VLOOKUP returns an error, THEN blank, ELSE do the VLOOKUP"

Dave
--
Brevity is the soul of wit.


"Paul LeBlanc" wrote:

I have a formula that returns a lookup value
=VLOOKUP(A10,VarietyLookUpTable!$A$2:$C$56,2,FALSE )
but when I try to make it so that there is no value in the cell if the
reference cell is blank
=IF(A12,VLOOKUP(A12,VarietyLookUpTable!$A$2:$C$56, 2,FALSE),"")
It only works if the cell is blank, if there is a value in the cell which is
formatted as text I get the #VALUE! instead of the usual result

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
Custom functions calculating time arguments Help Desperate Bill_De Excel Worksheet Functions 12 April 25th 06 02:22 AM
Vlookup Function Arguments are correct but nothing in cell Tom Excel Worksheet Functions 12 April 25th 06 12:41 AM
Help with VLookup function JohnK Excel Worksheet Functions 6 August 22nd 05 12:52 PM
Adding a Macro to a VLookup Function Wanda H. Excel Discussion (Misc queries) 1 August 16th 05 08:37 PM
VLOOKUP Function using Data Ranges. Cal Excel Worksheet Functions 6 April 16th 05 03:26 PM


All times are GMT +1. The time now is 06:59 AM.

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"