Conversion between cell name and row/column index

Get Cell Name from Row and Column Indices

It is possible to find a cell’s name given the row and column index. This article explains how.
Aspose.Cells for Python via .NET provides the CellsHelper.cell_index_to_name method which allows developers to get a cell’s name if they provide the row and column index.

The following sample code illustrates how to use CellsHelper.cell_index_to_name to access the cell’s name given a known row and column index. The code generates the following output.

Get Row and Column Indices from Cell Name

It is possible to find a row and column index of the cell from its name. This article explains how.
Aspose.Cells for Python via .NET provides the CellsHelper.cell_name_to_index method which allows developers to get a row and column index from the cell’s name.

The following sample code illustrates how to use CellsHelper.cell_name_to_index to get the row and column index from the cell’s name. The code generates the following output.

Create Safe Sheet Names

Sometimes there is a need to assign the sheet name at runtime. In this scenario, sheet names may contain characters such as < > + ( ? " that are not allowed. There is a need to replace any such character with a preset character provided by the user. Similarly, the length may exceed 31 characters, which needs to be truncated. Apache POI provides certain features for creating safe names; a similar feature is provided by Aspose.Cells for Python via .NET to handle all these issues. The following sample code demonstrates this feature:

Output:

this is first name which is cre

 <> + (adj.Private _ " Private"