Get Max Column Index in Row and Max Row Index in Column
Possible Usage Scenarios
When you only need to manipulate some data on the rows or columns, you need to know the data range of rows and columns. Aspose.Cells for Python via .NET offers this feature. To obtain the maximum column index on a row, you can obtain the Row.last_cell and Row.last_data_cell properties, and then use the Cell.column property to obtain the maximum column index and maximum data column index. But in order to obtain the maximum row index and maximum row data index on a column, you need to create a range on the column, then traverse the range to find the last cell, and finally obtain the Cell.row attribute on the cell.
Aspose.Cells for Python via .NET provides the following properties and methods to help you achieve your goals.
Get Max Column Index in Row and Max Row Index in Column using Aspose.Cells for Python Excel Library
This example shows how to:
- Load the sample file.
- Get the row that needs to get the maximum column index and maximum data column index.
- Get Cell.column attribute on the cell.
- Create a range based on column.
- Get iterator and traverse range.
- Get Cell.row attribute on the cell.