# help need to change a query!

#### j4ymf

##### Well-known Member
hello i have had some help over the past few days but i just cant get the last bit to work.

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))``

Code:
``=IF(ISBLANK(A26),"",VLOOKUP(A26,'Line 2'!\$A\$19:\$I\$28,3,FALSE))``

my aim is to get rid of all the #N/A errors when cells are empty.

right both codes do what i want them to do fine, code 2 looks at A26 to see if the cell is blank, if it is how ever it dose it it beyond me thats why im asking for help it dosent display the #N/a error the sheet is clean looking.

can someone change the first code so when the main cell is blank it dosent display the #N/A error

the only difference between the two codes are code 1 is looking at two refference sheets, and code2 is only looking at 1

thanks jason

does that make sence??????????

### Excel Facts

Copy formula down without changing references
If you have =SUM(F2:F49) in F50; type Alt+' in F51 to copy =SUM(F2:F49) to F51, leaving the formula in edit mode. Change SUM to COUNT.
sorry i forgot i posted somthing on the same lines last night but it has been sorted now thanks

result!!
Code:
``=IF(ISBLANK(A31),"",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)))``

Replies
3
Views
450
Replies
2
Views
287
Replies
14
Views
337
Replies
5
Views
552
Replies
2
Views
250

1,219,005
Messages
6,145,706
Members
450,635
Latest member
Rookie3510

### 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.

### Which adblocker are you using?

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

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