I am getting a type mismatch error trying to run a vlookup in VBA. The lookup range is in a different workbook. Relevant piece of code is below (wbkHarvester is declared and Set in another global module). Any suggestions? Thanks - Alicia
Dim intExchange As Integer
Dim strCampNum as String
'Determine camp number
strCampNum = rngBYCash.Value
intExchange = Application.WorksheetFunction.VLookup(strCampNum, _
Workbooks(wbkHarvester).Sheets(1).Range("Exchange.Rates"), 3, False)
Dim intExchange As Integer
Dim strCampNum as String
'Determine camp number
strCampNum = rngBYCash.Value
intExchange = Application.WorksheetFunction.VLookup(strCampNum, _
Workbooks(wbkHarvester).Sheets(1).Range("Exchange.Rates"), 3, False)