Get Started
Documentation

GetComment

GetComment() → { ApiComment | null }

Returns a ApiComment.

Parameters:

This method doesn't have any parameters.

Returns:

Type
ApiComment | null

Example

Copy code
builder.CreateFile("xlsx");
oWorksheet = Api.GetActiveSheet();
oRange = oWorksheet.GetRange("A1");
oRange.SetValue("1");
oRange.AddComment("This ia just a number.");
oWorksheet.GetRange("A3").SetValue("Comment: " + oRange.GetComment().GetText());
builder.SaveFile("xlsx", "GetComment.xlsx");
builder.CloseFile();

Resulting document