ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Vlookup multiple worksheets (https://www.excelbanter.com/excel-worksheet-functions/57062-vlookup-multiple-worksheets.html)

SMRTnotCMPTRSMRT

Vlookup multiple worksheets
 
The answer is probably posted on another thread but if you could help me out
I would appreciate it.

So far I have:
=VLOOKUP(x,[Table1.xls]Sheet1'!$1:$65536,2,FALSE)

which references one page, how would I search another workbook if a #N/A is
given back.



Dave Peterson

Vlookup multiple worksheets
 
You just check for the error and keep checking...

=IF(NOT(ISERROR(VLOOKUP(x,'[table1.xls]Sheet1'!1:65536,2,FALSE))),
VLOOKUP(x,'[table1.xls]Sheet1'!1:65536,2,FALSE),
IF(NOT(ISERROR(VLOOKUP(x,'[table1.xls]Sheet2'!1:65536,2,FALSE))),
VLOOKUP(x,'[table1.xls]Sheet2'!1:65536,2,FALSE)))

And watch your apostrophes--you didn't need the one you used, but if you used
it, you had to have each of the pair.




SMRTnotCMPTRSMRT wrote:

The answer is probably posted on another thread but if you could help me out
I would appreciate it.

So far I have:
=VLOOKUP(x,[Table1.xls]Sheet1'!$1:$65536,2,FALSE)

which references one page, how would I search another workbook if a #N/A is
given back.


--

Dave Peterson

Kleev

Vlookup multiple worksheets
 
I originally mistakenly you were asking to do a lookup on a different sheet
rather than a different workbook, but luckily, when I moved my sheet to a
different workbook, Excel changed my formulas accordingly. This would appear
to be what you are asking for. Note, it will return an #n/a if it also isn't
on the second workbook ...
=IF(ISNA(VLOOKUP(A1,Sheet1!$A$1:$B$5,2,FALSE)),VLO OKUP(A1,[ExampleMacros.xls]Diff!$A$1:$B$5,2,FALSE),VLOOKUP(A1,Sheet1!$A$1:$B$ 5,2,FALSE))

"SMRTnotCMPTRSMRT" wrote:

The answer is probably posted on another thread but if you could help me out
I would appreciate it.

So far I have:
=VLOOKUP(x,[Table1.xls]Sheet1'!$1:$65536,2,FALSE)

which references one page, how would I search another workbook if a #N/A is
given back.




All times are GMT +1. The time now is 10:56 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com