Get Started
Usage API
More information

GetAddress

GetAddress(RowAbs, ColAbs, RefStyle, External, RelativeTo) → { string | null }

Get cell address.

Parameters:

Name Type Description
RowAbs bool

Defines if the link to the row is absolute or not.

ColAbs bool

Defines if the link to the column is absolute or not.

RefStyle string

The reference style.

External bool

Defines if the range is in the current file or not.

RelativeTo range

The range which the current range is relative to.

Returns:

Type
string | null

Example

Copy code
builder.CreateFile("xlsx");
oWorksheet = Api.GetActiveSheet();
oWorksheet.GetRange("A1").SetValue("1");
oWorksheet.GetRange("B1").SetValue("2");
oAddress = oWorksheet.GetRange("A1").GetAddress(true, true, "xlA1", false);
oWorksheet.GetRange("A3").SetValue("Address: ");
oWorksheet.GetRange("B3").SetValue(oAddress);
builder.SaveFile("xlsx", "GetAddress.xlsx");
builder.CloseFile();

Resulting document