It will help you to find out last row count, column count then you can easily loop through your data according to requirement. Let's suppose your Excel contains blank cells then there is a different Code for that, you can easily use this in Visual Basic of Excel and Execute that in UiPath using activity Execute Macro. ***LastRow**** Range("A1").Select / Cells(1,1).Select lastrow = Range(Selection, ActiveCell.End(xlDown)).Rows.Count lastrow = ActiveSheet.UsedRange.Rows.Count ***LastColumn*** Range("A1").Select / Cells(1,1).Select lastcol = Range(ActiveCell.End(xlToRight), Selection).Columns.Count lastcol = ActiveSheet.UsedRange.Columns.Count ***LastRow With Spaces*** xIndex = Application.ActiveCell.Column xRowIndex = Application.ActiveSheet.Cells(Rows.Count, xIndex).End(xlUp).Row Range(Cells(1, xIndex), Cells(xRowIndex, xIndex)).Select lastrow = Selection.Count ***LastCol With Spaces*** xIndex = Application.ActiveCell.Row xCol...