![]() |
VLOOKUP in VBA
Hi,
I need to do a simple VLOOKUP through visual basic. All I want to do is set one of my variables equal to the result of a formula that would normally read: =VLOOKUP($C6,Codes!$B$C,2,FALSE) Things I don't want to do: Use a cell for the formula Use R[] C[] coding Define names Is there any way to do this? Thanks! Brett |
VLOOKUP in VBA
myVal =
Application.VLOOKUP(Range("C6").Value,Worksheets(" Codes").Range("B:C"),2,FAL SE) -- HTH Bob Phillips (replace somewhere in email address with gmail if mailing direct) wrote in message ups.com... Hi, I need to do a simple VLOOKUP through visual basic. All I want to do is set one of my variables equal to the result of a formula that would normally read: =VLOOKUP($C6,Codes!$B$C,2,FALSE) Things I don't want to do: Use a cell for the formula Use R[] C[] coding Define names Is there any way to do this? Thanks! Brett |
VLOOKUP in VBA
Thank you!
Bob Phillips wrote: myVal = Application.VLOOKUP(Range("C6").Value,Worksheets(" Codes").Range("B:C"),2,FAL SE) -- HTH Bob Phillips (replace somewhere in email address with gmail if mailing direct) wrote in message ups.com... Hi, I need to do a simple VLOOKUP through visual basic. All I want to do is set one of my variables equal to the result of a formula that would normally read: =VLOOKUP($C6,Codes!$B$C,2,FALSE) Things I don't want to do: Use a cell for the formula Use R[] C[] coding Define names Is there any way to do this? Thanks! Brett |
All times are GMT +1. The time now is 07:17 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com