The TXTextControl JavaScript object provides a public API to manipulate the web editor via JavaScript functions in the browser.

Syntax

TXTextControl

Enumerations

Enumeration Description
ActivationState The current activation state.
AddResult Specifies the result when a subtextpart has been added to the document.
AppendSettings Determines how text is appended to the document.
ApplicationFieldFormat The possible application field formats.
AutoBaseline Specifies how text is automatically sub- or superscripted.
AutoGenerationType Defines the type of document link auto-generation.
BarcodeAlignment Determines the alignment of the barcode image inside the control.
BarcodeTextAlignment Determines the alignment of the barcode text and additional text that is displayed inside the control.
BreakType Specifies where and how a text or section breaks.
CapitalizationSettings Specifies the settings for capitalization.
Capitals Specifies whether the lowercase letters of text are displayed with capital letters.
ChangeKind Specifies the kind of a tracked change.
ClipboardMode Possible clipboard modes.
ComponentRenderMode Component render mode.
ContextMenuLocation Determines the location in the document where a context menu will be shown.
ControlChars Determines values for the control characters used in a TextControl document.
DialogBoxKind Possible built-in dialog box types.
Direction Determines the writing direction of a paragraph.
DocumentAccessPermissions Specifies how a document can be accessed after it has been opened.
EditMode Determines the possible document edit modes.
FieldType Determines the possible MS Word specific merge field types supported by the TX Text Control JavaScript API.
FileType Specifies the kind of file types.
FindOptions Determines search options for the find method.
FontUnderlineStyle Specifies the style of the underline below a text.
FormulaReferenceStyle Specifies the style of references to table cells in formulas.
Frame Determines which frame borders are visible of an image, text frame, chart, barcode or drawing.
FrameInsertionMode Determines how the frame of an image, text frame, chart, barcode or drawing can be inserted in the text.
FrameStyle Determines the style of a frame of an image, text frame, chart, barcode or drawing.
HeaderFooterType Determines the type of a header or footer.
HighlightMode Contains all possible highlight mode values.
HorizontalAlignment Specifies the horizontal alignment of a text.
HtmlDialogBoxKind Possible built-in HTML based dialog box types.
ImageFormat Specifies the file format of an image.
ImageInsertionMode Determines how an image can be inserted in the text.
Justification Specifies the kind of justification.
ListFormatCharacter Specifies the list format character.
ListType Specifies the type of a list.
MeasuringUnit Specifies the measuring unit.
MergeFieldTextFormat Determines the possible text formats for merge fields containing text.
MisspelledWordKind Specifies the kind of a misspelled word.
NumberFormat Specifies the format of a numbered list.
PageContent Defines the contents of a page's image returned from the Page.getImage method.
PermanentControlChar Defines a control character which is shown permanently on the screen.
RelationalOperator Determines the relational operator used by some types of merge fields.
RulerBarBorderStyle The border style of a ruler bar.
RulerBarFormulaMode Specifies whether a ruler bar shows cell references when the current input position is in a table cell.
RulerBarScaleUnit Specifies whether a ruler bar shows cell references when the current input position is in a table cell.
SectionBreakKind Specifies the kind of a section break.
SideBarType Specifies the existing side bar types.
SpecialZoomFactor Determines the special zoom factor values for property TXTextControl.zoomFactor.
StatusBarBorderStyle The border style of a status bar.
StreamType Determines a certain text format.
TabLeader Defines how a tab gap is filled.
TabType Determines the tabulator type.
TableAddPosition Specifies the position where to split the table.
TextFieldPosition Specifies special text input positions at the beginning and the end of a text field.
TextFieldType Possible types of text fields.
TextFrameInsertionMode Determines how a text frame can be inserted in the text.
TextType Specifies how a text is represented and interpreted.
VerticalAlignment Specifies the vertical alignment of a text.
ViewMode The mode how Text Control displays a document.
ZOrder Specifies how the z-order of a frame (image, text frame, chart, barcode or drawing) can be changed.

Methods

Method Description
addEventListener The addEventListener function registers event listener functions on the TXTextControl object.
addMergeField Inserts a merge field at the current input position.
addTextField Obsolete.
append Appends text to the document in a certain format.
appendDocument Appends text in a certain format to the current document.
atobUTF8 Decodes a string of data which has been encoded using base-64 encoding.
beginUndoAction Begins a user-defined undo operation.
btoaUTF8 Creates a base-64 encoded ASCII string from a unicode string.
clear Clears the selected text or the character right from the current input position.
clearUndo Clears the undo buffer.
endUndoAction Ends a user-defined undo operation.
find Finds a text string.
(Inherited from FormattedText)
focus Sets the text input focus to the web editor.
getActivationState Gets a value indicating the current activation state.
getAllowUndo Gets a value indicating whether the undo buffer is active or not.
getBackColor Gets the Text Control's background color.
getBaseline Gets the baseline alignment, in twips, of the Text Control.
getCanCharacterFormat Informs whether the currently selected text can be formatted with character formatting attributes.
getCanCopy Informs whether a part of a Text Control document has been selected and can be copied to the clipboard.
getCanDocumentFormat Informs whether the document can be formatted with page and section formatting attributes.
getCanPaste Informs whether the document's text and/or formatting attributes can be changed.
getCanPrint Informs whether the document can be printed.
getCanRedo Informs whether an operation can be re-done using the Redo method.
getCanStyleFormat Informs whether the document can be formatted with formatting styles.
getCanTableFormat Informs whether the currently selected text can be formatted with table formatting attributes.
getCanUndo Gets a value indicating whether the user can undo the previous operation in a Text Control.
getCommentHighlightMode Gets the global comment highlight mode.
getControlChars Gets whether the control characters are visible or not.
getCultures Returns the culture and the UI culture of the control.
getDocumentTargetMarkers Gets a value indicating that markers for hypertext targets are shown or not.
getDrawingMarkerLines Gets whether a marker frame is shown around a drawing to indicate its position and size.
getEditMode Gets a value indicating whether the document's text is protected, or can be freely edited and formatted.
getEditableRegionHighlightMode Gets the global editable region highlight mode.
getFileDirectory Obsolete.
getFontUnderlineStyle Gets underlining style for the text displayed by the control.
getForeColor Gets the foreground color of the control which is the color of the document's text.
getFormattingPrinter Returns the name of the currently selected formatting printer by calling a provided callback function.
getFormulaReferenceStyle Gets a value determining how references to table cells in formulas are specified.
getInstalledPrinters Gets the names of the printers installed on the server which are usable by Text Control.
getIsFormFieldValidationEnabled Gets a value indicating whether form field validation is active or not.
getIsFormulaCalculationEnabled Gets a value indicating whether formulas in tables are automatically calculated when the text of an input cell is changed.
getIsHyphenationEnabled Gets a value indicating whether hyphenation is active or not.
getIsLanguageDetectionEnabled Gets a value indicating whether language detection is active or not.
getIsSpellCheckingEnabled Gets a value indicating whether spell checking is active or not.
getIsTrackChangesEnabled Gets a value indicating whether track changes is active or not.
getLandscape Gets a value indicating whether the page orientation is landscape.
getPageCount Gets the number of pages contained in the current document.
getPageUnit Gets the measure used for page sizes and page margins.
getPermanentControlChars Gets a value indicating which control characters are shown permanently on the screen.
getRedoActionName Gets a string that represents the name of the action that will be performed when a call to the redo method is made.
getRenderMode Gets the component render mode.
getSelectObjects Gets a value controlling the selection of objects which are inserted behind the text.
getStatusBarColor Returns the background color of the status bar by calling a provided callback function.
getSubTextParts Obsolete.
getSupportedFonts Gets an array of strings specifying the names of all currently supported fonts.
getSupportedPaperSizes Gets an array of PaperSize structures specifying the names and the size of all currently supported paper sizes.
getText Gets the control's text.
getTextBackColor Gets the background color for the text.
getTextFields Obsolete.
getTextFieldsByType Returns an array of static text field information objects.
(Inherited from FormattedText)
getTextFrameMarkerLines Gets whether text frames that have no border line are shown with marker lines.
getTextParts Obsolete.
getUndoActionName Gets a string that represents the name of the action that will be performed when a call to the undo method is made.
getUserNames Gets a list of names specifying users who have access to editable regions.
getViewMode Gets the mode how Text Control displays a document.
init Initializes the document editor.
load Loads text in a certain format.
loadDocument Loads text in a certain format.
loadJsonData Loads JSON data which is used to create table and field name menu items in the mailings ribbon tab.
loadSelection Obsolete.
loadXMLDatabase Loads an XML database which is used to create table and field name menu items in the mailings ribbon tab.
printDocument Attempts to print the current document in the browser.
redo Redoes the last Text Control operation.
refreshLayout Forces a layout refresh of the document editor.
removeEventListener The removeListener function removes the specified event listener from the TXTextControl object.
removeFromDom Closes the WebSocket connection gracefully and removes the whole editor from the DOM.
removeTextField Obsolete.
resetContents Deletes the entire contents of the control.
save Saves the current document in a certain format and sends the result back asynchronously by calling a given callback function.
saveDocument Saves the current document in a certain format and sends the result back asynchronously by calling a given callback function.
saveSelection Obsolete.
select Selects text within the control.
selectAll Selects all text in the control.
selectWord Selects the word at the current text input position.
setActivationState Sets a value indicating the current activation state.
setAllowUndo Sets a value indicating whether the undo buffer is active or not.
setBackColor Sets the Text Control's background color.
setBaseline Sets the baseline alignment, in twips, of the Text Control.
setCommentHighlightMode Sets the global comment highlight mode.
setControlChars Sets whether the control characters are visible or not.
setDocumentTargetMarkers Sets a value indicating that markers for hypertext targets are shown or not.
setDrawingMarkerLines Sets whether a marker frame is shown around a drawing to indicate its position and size.
setEditMode Sets a value indicating whether the document's text is protected, or can be freely edited and formatted.
setEditableRegionHighlightMode Sets the global editable region highlight mode.
setFileDirectory Sets the directory path where the files of a specific file type are stored on the web server.
setFontUnderlineStyle Sets underlining style for the text displayed by the control.
setForeColor Sets the foreground color of the control which is the color of the document's text.
setFormattingPrinter Sets the name of a printer the text dimensions and capabilities of which are used to format the document.
setFormulaReferenceStyle Sets a value determining how references to table cells in formulas are specified.
setInputPositionByLocation Sets a new input position from a geometric location.
setInputPositionByPage Sets a new input position from a page, line and column number.
setInputPositionByTextPosition Sets a new input position from a text position.
setIsFormFieldValidationEnabled Sets a value indicating whether form field validation is active or not.
setIsFormulaCalculationEnabled Sets a value indicating whether formulas in tables are automatically calculated when the text of an input cell is changed.
setIsHyphenationEnabled Sets a value indicating whether hyphenation is active or not.
setIsLanguageDetectionEnabled Sets a value indicating whether language detection is active or not.
setIsSpellCheckingEnabled Sets a value indicating whether spell checking is active or not.
setIsTrackChangesEnabled Sets a value indicating whether track changes is active or not.
setLandscape Sets a value indicating whether the page orientation is landscape.
setPageUnit Sets the measure used for page sizes and page margins.
setPermanentControlChars Sets a value indicating which control characters are shown permanently on the screen.
setRenderMode Sets the component render mode.
setSelectObjects Sets a value controlling the selection of objects which are inserted behind the text.
setStatusBarColor Sets the background color of the status bar.
setText Sets the control's text.
setTextBackColor Sets the background color for the text.
setTextFrameMarkerLines Sets whether text frames that have no border line are shown with marker lines.
setViewMode Sets the mode how Text Control displays a document.
showDialog Shows a built-in dialog box.
showHorizontalRuler Shows or hides the web editor's horizontal ruler bar.
showHtmlDialog Shows one of the a built-in HTML dialog boxes.
showMergeFieldDialog Opens a field dialog either for changing properties of an existing merge field or for creating a new merge field.
showRibbonBar Shows or hides the ribbon bar.
showSideBar Shows or hides a specified side bar.
showStatusBar Shows or hides the web editor's status bar.
showVerticalRuler Shows or hides the web editor's vertical ruler bar.
undo Undoes the last Text Control operation.
zoom Zooms the contents of the TextControl.

Properties

Property Description
applicationFields Gets a collection of all Microsoft Word fields that have been created or imported from a Microsoft Word or RTF document.
(Inherited from FormattedText)
barcodeTypeSettings The type specific settings for the currently used barcode.
barcodes Gets a collection of all barcode frames contained in the text part with the input focus.
clipboardMode Gets or sets the clipboard mode (client or server).
comments Gets a collection of all comments in this text part.
(Inherited from FormattedText)
contextMenusEnabled Gets or sets if a right click into the text area opens a context menu or not.
controlChars Obsolete.
displayColors The displayed colors of the text control.
documentLinks Gets a collection of all links which point to targets in the same document.
(Inherited from FormattedText)
documentPermissions The document permission settings.
documentSettings The DocumentSettings class provides properties which inform about general document settings, such as author and title, contained in the document the user is currently working on.
documentTargetMarkers Gets or sets whether document target markers are visible.
documentTargets Gets a collection of all document targets.
(Inherited from FormattedText)
editMode Obsolete.
editableRegions Gets a collection of all editable regions.
(Inherited from FormattedText)
footnotes All footnotes contained in the main text of the document.
formFields Gets a collection of all form fields in the text part.
(Inherited from FormattedText)
frames Gets a collection of all frames in the document.
(Inherited from FormattedText)
headersAndFooters Gets a collection of all headers and footers in the document.
hypertextLinks Gets a collection of all hypertext links.
(Inherited from FormattedText)
images Gets a collection of all images contained in the text part with the input focus.
inlineStyles Gets a collection of all inline styles the current document contains.
inputFormat All formatting attributes at the current text input position.
inputPosition The current text input position.
isHyphenationEnabled Obsolete.
isLanguageDetectionEnabled Obsolete.
isLoadingDialogEnabled Gets or sets whether a wait dialog is shown while a document is being loaded.
isSpellCheckingEnabled Obsolete.
isTrackChangesEnabled Obsolete.
lines Gets a collection of all text lines.
(Inherited from FormattedText)
listFormat The type and the formatting attributes of a bulleted or numbered list.
misspelledWords Gets a collection of all misspelled words.
(Inherited from FormattedText)
pageMargins The margins for the pages of the current document.
pageSize The width and height of the pages for the current document.
pages Gets a collection of all pages in the document.
paragraphFormat The paragraph formatting attributes of the text displayed by the control.
paragraphStyles All paragraph formatting styles in the current document.
paragraphs Gets a collection of all paragraphs.
(Inherited from FormattedText)
ribbon Gets the control's ribbon bar object.
ribbonPermissionsTab Returns the "Permissions" ribbon tab object.
rulerBar The horizontal ruler bar.
saveDocumentQuestionDialogEnabled Obsolete.
sections Gets a collection of all sections in the document.
selection Gets the current selection.
(Inherited from FormattedText)
sideBarToggleButton The sidebar toggle button shown at the top right of the ribbon.
signatureFields Gets a collection of all signature fields in the document.
statusBar The status bar.
subTextParts Gets the current subtextparts.
(Inherited from FormattedText)
tableGridLines Gets or sets if table grid lines are visible.
tables Gets a collection of all tables.
(Inherited from FormattedText)
tablesOfContents Gets the current tables of contents.
(Inherited from FormattedText)
textChars Gets a collection of all text characters.
(Inherited from FormattedText)
textFields Gets a collection of all standard text fields.
(Inherited from FormattedText)
textFieldsEditable Gets or sets if text fields are editable or not.
textFrameMarkerLines Gets or sets if text frame marker lines are visible.
textFrames Gets a collection of all text frames in the document.
textPartType Gets the Text part type.
(Inherited from FormattedText)
textParts Gets a collection of all main text parts the current document contains.
trackedChanges Gets a collection of all tracked changes.
(Inherited from FormattedText)
verticalRulerBar The vertical ruler bar.
zoomFactor Obsolete.