VLOOKUP with IF function

G

Guest

I have used the VLookup function on an invoice that will print the price and
description of an item when the item number is typed in. I want to removed
the #N/A from the invoice when the lines are blank. I was told to use the IF
function.

My lookup function is =VLOOKUP(A24,Product!A8:D14,2)

If I add the IF function to it-- would it look like

=IF(A24="","")=VLOOKUP(A24,Product!A8:D14,2) ?

Or just where would the IF formula go and did I type it correctly to say if
the cell is empty?

Thanks
Bev
 
G

Guest

=IF(ISERR(putyourvlookuphere)=TRUE,"",putyourvlookuphere)

It could look something like I have above. It will check to see if the
result is an error #N/A included I believe, if it is it will put in a blank,
if not it will put the actual result of the vlookup.
 
B

Biff

ISERR excludes #N/A.

ISERROR handles all of the error types.
=IF(ISERR(putyourvlookuphere)=TRUE,"",putyourvlookuphere)

Since the ISERR(OR) function returns a boolean, either TRUE or FALSE,
there's no need for an equality comparison:

ISERR(putyourvlookuphere)=TRUE

ISERR(putyourvlookuphere) will do.

Biff
 
G

Guest

just thinking...does each of your invoice spreadsheet needs to be saved each
time you create one with a served invoice number ? If you do, better clean
the non-servable formula....Just try to maintain a template filled with the
formula for your next invoicing....
 

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