You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: ej2-react/document-editor/content-control.md
+74-2Lines changed: 74 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -10,7 +10,7 @@ domainurl: ##DomainURL##
10
10
11
11
# Content control in React Document editor control
12
12
13
-
Document Editor provides content control preservation support (i.e.) Content control present in the input document is preserved upon saving.
13
+
Document Editor provides support for inserting, editing content controls.
14
14
15
15
Content controls can be categorized based on its occurrence in a document as follows,
16
16
@@ -26,4 +26,76 @@ BlockContentControl: Among paragraphs and tables, as a child of a Body, HeaderFo
26
26
* Drop-Down List and Combo Box
27
27
* Picture
28
28
29
-
>Note: Content control with custom XML mapping of file type WordML is converted as normal Rich Text Content Control to provide lossless round-tripping upon saving.
29
+
## Insert content control
30
+
31
+
Content control can be inserted using [`insertContentControl`](https://ej2.syncfusion.com/react/documentation/api/document-editor/editor/#insertcontentcontrol) method in editor module.
Content control properties can be set using the [`ContentControlInfo`](https://ej2.syncfusion.com/react/documentation/api/document-editor/contentControlInfo/) and import it using [`importContentControlData`](https://ej2.syncfusion.com/react/documentation/api/document-editor/#importcontentcontroldata)
Content control properties can be exported using the [`exportContentControlData`](https://ej2.syncfusion.com/react/documentation/api/document-editor/#exportcontentcontroldata)
85
+
86
+
{% highlight ts %}
87
+
let contentControlInfos: ContentControlInfo[] = this.container.documentEditor.exportContentControlData();
88
+
{% endhighlight %}
89
+
90
+
## Reset content control
91
+
92
+
Content control properties can be reset using the [`resetcontentcontroldata`](https://ej2.syncfusion.com/react/documentation/api/document-editor/#resetcontentcontroldata)
>Note: Content control with custom XML mapping of file type WordML is converted as normal Rich Text Content Control to provide lossless round-tripping upon saving.
0 commit comments