TRY NEW VERSION

Try now New API BETA

Try out the new view and capabilities of the API documentation

START

GetRangeByNumber

GetRangeByNumber(nRow, nCol) → { ApiRange }

Returns an object that represents the selected range of the current sheet using the row/column coordinates for the cell selection.

Parameters:

Name Type Description
nRow number

The row number.

nCol number

The column number.

Returns:

Type
ApiRange

Example

Copy code
builder.CreateFile("xlsx");
var oWorksheet = Api.GetActiveSheet();
oWorksheet.GetRangeByNumber(1, 2).SetValue("42");
builder.SaveFile("xlsx", "GetRangeByNumber.xlsx");
builder.CloseFile();

Resulting document