troubleshooting Question

Dynamic VLOOKUP formula in VBA procedure

Avatar of RWayneH
RWayneHFlag for United States of America asked on
Microsoft OfficeMicrosoft ExcelVBA
2 Comments1 Solution179 ViewsLast Modified:
I have a need for a dynamic VLOOKUP formula within a vba procedure.
I am using, ActiveCell.FormulaR1C1 = "=VLOOKUP(RC[-37],Inventory!C[-14]:C[-5],10,FALSE)"
The dynamic part is the [-37] which refers to column A.

How would I change the formula to point to Column A, no matter the cell that the formula gets put into, so it honors the proper value being used in the VLOOKUP?
Please advise and thanks.
NorieAnalyst Assistant
Join our community to see this answer!
Unlock 1 Answer and 2 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 2 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros