Hi Jack,

Thanks for using Aspose.Cells.

For your requirement, here is a one solution you may try.

**Java**

Workbook wb = new Workbook(“VLOOKUP.xlsx”);

Cells cellsData = wb.Worksheets[0].Cells;

int maxDataCol = cellsData.MaxDataColumn + 1;

int maxDataRow = cellsData.MaxDataRow + 1;

Cell cell = cellsData[0, maxDataCol];

cell.SetSharedFormula("=ROW()", maxDataRow, 1);

Worksheet sheetView = wb.Worksheets[1];

Cells cellsView = sheetView.Cells;

cellsView.Columns[0].IsHidden = true;

cell = cellsView[2, 0];

maxDataCol++;

cell.SetSharedFormula("=VLOOKUP(INDIRECT(“Sheet1!A”&$A$1),INDIRECT(“Sheet1!A”&(A2+1)&":"&""

+ CellsHelper.CellIndexToName(maxDataRow, maxDataCol) + “”)," + maxDataCol + “,FALSE)”,

maxDataRow, 1);

cell = cellsView[2, 1];

cell.SetSharedFormula("=IFERROR(OFFSET(INDIRECT(“Sheet1!A”&$A3),0,COLUMN()-2),"")", maxDataRow, maxDataCol - 1);

ShapeCollection shapes = sheetView.Shapes;

Shape s = shapes.AddShape(MsoDrawingType.ComboBox, 0, 0, 1, 0, 30, 100);

ComboBox cb = (ComboBox)s;

cb.InputRange= “Sheet1!A1:A” + maxDataRow;

cb.LinkedCell = “A1”;

wb.Save(“res.xlsx”);