RemoveReplies
Removes the specified comment replies.
Parameters:
Name |
Type |
Default |
Description |
nPos |
Number
|
0 |
The position of the first comment reply to remove. |
nCount |
Number
|
1 |
A number of comment replies to remove. |
bRemoveAll |
boolean
|
false |
Specifies whether to remove all comment replies or not. |
Returns:
- Type
-
ApiComment
Example
Copy code
builder.CreateFile("docx");
var oDocument = Api.GetDocument();
var oParagraph = oDocument.GetElement(0);
oParagraph.AddText("This is just a sample text");
Api.AddComment(oParagraph, "comment", "John Smith");
var aComments = oDocument.GetAllComments();
aComments[0].AddReply("reply1", "Mark Potato", "uid-2", 0);
aComments[0].RemoveReplies();
oParagraph = Api.CreateParagraph();
oParagraph.AddText("The comment replies were removed");
oDocument.Push(oParagraph);
builder.SaveFile("docx", "RemoveReplies.docx");
builder.CloseFile();
Resulting document