Hi all
Does anyone have time to help me with the code below. I have attempted to write code with a double lookup criteria and it isn't working.
Thanks so much in advance!
Does anyone have time to help me with the code below. I have attempted to write code with a double lookup criteria and it isn't working.
Thanks so much in advance!
VBA Code:
Dim ActiveRow As Long
ActiveRow = ActiveCell.Row
Dim tblartist As Range
Dim tblname As Range
Dim tbleref As Range
Set tblartist = Worksheets("sheet1").ListObjects("Table1").ListColumns(14).DataBodyRange
Set tblname = Worksheets("sheet1").ListObjects("Table1").ListColumns(5).DataBodyRange
Set tbleref = Worksheets("sheet1").ListObjects("Table1").ListColumns(1).DataBodyRange
TextBox1.Value = WorksheetFunction.XLookup((ActiveRow, 5) & (ActiveRow, 7), tblartist & tblname, tbleref)