View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
BrianB BrianB is offline
external usenet poster
 
Posts: 1
Default call VLOOKUP from Macro with Variables

The basic code is something like this :-

Code
-------------------

Dim MyRange As Range
Set MyRange = Worksheets("Sheet1").Range("Mylookup")
ActiveCell.Value = _
Application.WorksheetFunction.VLookup(name1, MyRange, 5, 0)

-------------------


--
Message posted from http://www.ExcelForum.com