# vlookup query

#### j4ymf

##### Well-known Member
hello folks

i was wondering if someone could give us a hand please

ive got this query
=VLOOKUP(\$A\$4,'Line 1 '!\$A\$19:\$K\$59,5,FALSE)

\$A\$4 =xyz and the ,5, = 123 = result 123

the query works fine and does what i need it to do, but i want to make my sheet look pretty when the is nothing in A4

so if i have got xyz in A4, my result will be 123
if i have an empty cell in A4 i get #N/A

can i use conditional formatting with white text or somthing like that so it dosent show anything until somthing is in cellA4 ??????????
do you get what i mean

many thanks jason

### Excel Facts

How to show all formulas in Excel?
Press Ctrl+` to show all formulas. Press it again to toggle back to numbers. The grave accent is often under the tilde on US keyboards.
How about

=IF(ISBLANK(A4),"",VLOOKUP(\$A\$4,'Line 1 '!\$A\$19:\$K\$59,5,FALSE))

you are a star

that worked fantastic.

can i just ask 1 more favour,

if i write somthing in cell A7 like joe bloggs can i also hide that if cell A4 is balnk??????

=IF(ISBLANK(A4)joe bloggs

Yes, it is quite general:

=IF(ISBLANK(A4),"","joe bloggs")

TOP BANANA

many thanks

sorry last one to clear the sheet

ive got in cell A8 (=C4/A7) result = #VALUE!

C4 is blank
A7 is =IF(ISBLANK(C4),"",VLOOKUP(\$A\$4,'Line 1 '!\$A\$19:\$K\$59,11,FALSE))

whats your thoughts so i can clear the #VALUE!, or white the text out untill C4 has got somthing in it.............

many thanks

Can use the same ISBLANK formula again

A8 = IF(ISBLANK(C4),"",C4/A7)

sorry didnt work for me!!!!!!!!!

=IF(ISBLANK(C4),"",C4/A7)

just leaves =IF(ISBLANK(C4),"", in the cell

mmmmmmmmmmmmmmmmmmm

sorry my fault, i had a space b4 the =

thanks for your help

hello again

from last nights help i got this to work
Code:
``=IF(ISBLANK(A26),"",VLOOKUP(A26,'Line 2'!\$A\$19:\$I\$28,3,FALSE))``

so if A26 is blank it will leave the cell empty that works fine. and the sheet looking neat.

so what do i need to do to this one then?
Code:
``=IF(ISNA(VLOOKUP(\$A\$31,'Line 3 Cat - Export Dog'!\$A\$22:\$I\$45,3,FALSE)),VLOOKUP(\$A\$31,'Line 3'!A30:I81,3,FALSE),VLOOKUP(\$A\$31,'Line 3 Cat - Export Dog'!\$A\$22:\$I\$45,3,FALSE))``

when A31 is empty it leaves #N/A as b4

thanks jason

Replies
0
Views
1K
Replies
7
Views
328
Replies
1
Views
274
Replies
1
Views
484
Replies
1
Views
347

Threads
1,217,387
Messages
6,136,295
Members
450,002
Latest member
bybynhoc

### We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

### Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

### Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

### Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

### Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back