Vlookup to closed workbook ?

  • Thread starter Thread starter Les Stout
  • Start date Start date
Simple enough Les, just like so

=VLOOKUP("b",'C:\Documents and
Settings\Bob\Desktop\[Def_sample.xls]Sheet2'!$A$1:$B$6,2,FALSE)

You shoukld be able top work it out to suit your workbook.

--

HTH

RP
(remove nothere from the email address if mailing direct)
 
Bob gave you a good answer for using in a worksheet cell.

You can't do that in VBA code however. You would need to have your code
put the formula in a cell and then get the value it returns.

there are other methods, but none that are as direct or as fast.

John Walkenbach's site
http://www.j-walk.com/ss/excel/tips/tip82.htm
A VBA Function to Get a Value From a Closed File

You can modify the formula to do a Vlookup

Ron de Bruin's site
http://www.rondebruin.nl/ado.htm
Copy a range from closed workbooks (ADO)
 

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

Similar Threads


Back
Top