Get Started
Documentation

GetClassType

GetClassType() → { "blockLvlSdt" }

Get the type of this class.

Returns:

Type
"blockLvlSdt"

Example

Copy code
builder.CreateFile("docx");
oDocument = Api.GetDocument();
oBlockLvlSdt = Api.CreateBlockLvlSdt();
oParagraph = Api.CreateParagraph();
oBlockLvlSdt.GetContent().GetElement(0).AddText("This is a block text content control.");
oDocument.AddElement(0, oBlockLvlSdt);
oClassType = oBlockLvlSdt.GetClassType();
oParagraph = oDocument.GetElement(1);
oParagraph.AddText("Class type: " + oClassType);
builder.SaveFile("docx", "GetClassType.docx");
builder.CloseFile();

Resulting document