跳到主要内容

ApiBlockLvlSdt

Represents the ApiBlockLvlSdt class.

Methods

MethodReturnsDescription
AddCaptionbooleanAdds a caption paragraph after (or before) the current content control.\ 💡 Please note that the current content control must be in the document (not in the footer/header).\ And if the current content control is placed in a shape, then a caption is added after (or before) the parent shape.
AddCommentApiCommentAdds a comment to the current block content control.\ 💡 Please note that the current block content control must be in the document.
AddElementbooleanAdds a paragraph or a table or a block content control to the current container.
AddTextbooleanAdds a text to the current content control.
CopyApiBlockLvlSdtCreates a copy of an block content control. Ignores comments, footnote references, complex fields.
DeletebooleanRemoves a content control and its content. If keepContent is true, the content is not deleted.
GetAliasstringReturns the alias attribute for the current container.
GetAllContentControlsApiBlockLvlSdt[] | ApiInlineLvlSdt[]Returns a collection of content control objects in the current content control.
GetAllDrawingObjectsDrawing[]Returns a collection of drawing objects in the current content control.
GetAllParagraphsApiParagraph[]Returns a collection of paragraph objects in the current content control.
GetAllTablesOnPageApiTable[]Returns a collection of tables on a given absolute page.\ 💡 This method can be a little bit slow, because it runs the document calculation\ process to arrange tables on the specified page.
GetClassType"blockLvlSdt"Returns a type of the ApiBlockLvlSdt class.
GetContentApiDocumentContentReturns the content of the current container.
GetDropdownListApiContentControlListReturns a list of values of the combo box / dropdown list content control.
GetInternalIdstringReturns an internal id of the current content control.
GetLabelstringReturns the label attribute for the current container.
GetLockSdtLockReturns the lock type of the current container.
GetParentContentControlApiBlockLvlSdt | nullReturns a content control that contains the current content control.
GetParentTableApiTable | nullReturns a table that contains the current content control.
GetParentTableCellApiTableCell | nullReturns a table cell that contains the current content control.
GetPlaceholderTextstringReturns the placeholder text from the current content control.
GetPosInParentNumberReturns the content control position within its parent element.
GetRangeApiRangeReturns a Range object that represents the part of the document contained in the specified content control.
GetTagstringReturns the tag attribute for the current container.
MoveCursorOutsideNonePlaces a cursor before/after the current content control.
PushbooleanPushes a paragraph or a table or a block content control to actually add it to the current container.
RemoveAllElementsbooleanClears the contents from the current content control.
ReplaceByElementbooleanReplaces the current content control with a new element.
SearchApiRange[]Searches for a scope of a content control object. The search results are a collection of ApiRange objects.
SelectNoneSelects the current content control.
SetAliasNoneSets the alias attribute to the current container.
SetLabelNoneSets the label attribute to the current container.
SetLockNoneSets the lock to the current block text content control:\ -"contentLocked" - content cannot be edited.\ -"sdtContentLocked" - content cannot be edited and the container cannot be deleted.\ -"sdtLocked" - the container cannot be deleted.
SetPlaceholderTextbooleanSets the placeholder text to the current content control.
SetTagNoneSets the tag attribute to the current container.
SetTextPrNoneApplies text settings to the content of the content control.
ToJSONJSONConverts the ApiBlockLvlSdt object into the JSON object.