Contains all comments in the main text or another part of a document. All comments are associated with a certain piece of text of the document. The collection consists of CommentedText objects, describing the position and length of the commented text and the comment string itself. A collection object can be obtained with the FormattedText.comments property.

Syntax

CommentCollection

Introduced: 30.0.

Methods

Method Description
add Creates a comment with the specified comment string.
addAtPosition Creates a comment with the specified comment string, start position and length.
addReply Creates a reply to an existing comment using the specified comment string.
elementAt Returns the element at a specified index in the collection.
(Inherited from Collection)
forEach Executes a callback function for each element.
(Inherited from Collection)
getCount Gets the number of elements contained in the collection.
(Inherited from Collection)
getItem Gets the Comment containing the current text input position from the collection.
getNextItem Gets the next comment in the text flow.
getPreviousItem Gets the previous comment in the text flow.
remove Removes a comment from the collection.