ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Vlookup (https://www.excelbanter.com/excel-programming/342860-vlookup.html)

Nicole D.

Vlookup
 
How do I call the Vlookup function in VB?

Rbp9ad[_2_]

Vlookup
 
Application.VLookup(Arguments)
or
Application.worksheetfunctions.VLookup(Arguments)

"Nicole D." wrote in message
...
How do I call the Vlookup function in VB?




Nicole D.

Vlookup
 
Thanks. Why wouldn't this work

Sheet3.Range("AL2").Value = Application.WorksheetFunction.VLookup(C2, Pull,
7, False)


"Rbp9ad" wrote:

Application.VLookup(Arguments)
or
Application.worksheetfunctions.VLookup(Arguments)

"Nicole D." wrote in message
...
How do I call the Vlookup function in VB?





Jim Thomlinson[_4_]

Vlookup
 
You need to explictly reference the ranges so that VB has some idea where to
look. In this case addresses won't cut it...

Something like...

Sheet3.Range("AL2").Value =
Application.WorksheetFunction.VLookup(Sheet3.Range ("C2"),
Sheet3.Range("Pull"), 7, False)
--
HTH...

Jim Thomlinson


"Nicole D." wrote:

Thanks. Why wouldn't this work

Sheet3.Range("AL2").Value = Application.WorksheetFunction.VLookup(C2, Pull,
7, False)


"Rbp9ad" wrote:

Application.VLookup(Arguments)
or
Application.worksheetfunctions.VLookup(Arguments)

"Nicole D." wrote in message
...
How do I call the Vlookup function in VB?






All times are GMT +1. The time now is 09:05 AM.

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