Hi,
I'm trying to get macro to look up different workbook (CIT export.xlsx) and choose name of the sheet in that workbook based on value from cell A2 in current workbook. So, instead of 'AT01' in the formula, there should be value from the A2 cell. Is there a way to do this? So far I tried a bunch off different methods but nothing seems to work.
ActiveCell.FormulaR1C1 = _
"=VLOOKUP(RC[-15],'[CIT export.xlsx]AT01'!C4:C19,16,0)"
I'm trying to get macro to look up different workbook (CIT export.xlsx) and choose name of the sheet in that workbook based on value from cell A2 in current workbook. So, instead of 'AT01' in the formula, there should be value from the A2 cell. Is there a way to do this? So far I tried a bunch off different methods but nothing seems to work.
ActiveCell.FormulaR1C1 = _
"=VLOOKUP(RC[-15],'[CIT export.xlsx]AT01'!C4:C19,16,0)"