Get Started
Documentation

GetParaPr

GetParaPr() → {ApiParaPr}

The paragraph properties which are applied to any numbered paragraph that references the given numbering definition and numbering level.

Returns:

Type
ApiParaPr

Example

Copy code
builder.CreateFile("docx");
var oDocument = Api.GetDocument();
var oParagraph, oNumbering, oNumLvl, oParaPr;
oNumbering = oDocument.CreateNumbering("numbered");
oNumLvl = oNumbering.GetLevel(0);
oParaPr = oNumLvl.GetParaPr();
oParaPr.SetSpacingLine(480, "auto");
oParaPr.SetJc("both");
oParaPr.SetIndFirstLine(720);
oParagraph = oDocument.GetElement(0);
oParagraph.SetNumbering(oNumLvl);
oParagraph.AddText("This is the first element of a parent numbered list which starts with '1'");
oParagraph = Api.CreateParagraph();
oParagraph.AddText("This is the second element of a parent numbered list which starts with '2'");
oParagraph.SetNumbering(oNumLvl);
oDocument.Push(oParagraph);
builder.SaveFile("docx", "GetParaPr.docx");
builder.CloseFile();

Resulting document