Get Started
Documentation

GetIndex

GetIndex() → { Number }

Get the row index.

Returns:

Type
Number

Example

Copy code
builder.CreateFile("docx");
oDocument = Api.GetDocument();
oTable = Api.CreateTable(3, 3);
oTable.SetWidth("percent", 100);
oRow = oTable.GetRow(1);
oRow.GetCell(0).GetContent().GetElement(0).AddText("Row index: " + oRow.GetIndex());
oDocument.Push(oTable);
builder.SaveFile("docx", "GetIndex.docx");
builder.CloseFile();