May 17, 2017

Vlookup from multiple tables

How to vlookup data from multiple tables using choose in VBA. Watch the training video below:


Watch this video on YouTube.

Here’s the VBA code to lookup data from multiple tables quickly and easily:

Sub vLookup_choose()
Range(“C3”).Value = “=VLookup(B3, Choose(VLookup(A3, companyindex, 2, 0), company1, company2, company3), 2, False)”
Range(“C3”).AutoFill Destination:=Range(“C3:C5”), Type:=xlFillDefault
End Sub

Further reading:

CHOOSE Function