editComment

Description

Edits a comment with the specified id and text. Returns the comment representation after the edit.

Return Type

CComment

Examples

Example 1

Edits the comment with id 11801 with the specified text.

string newComm = "This comment was edited."; return editComment(11801, newComm);

Example 2

Edits a comment by adding new text to the old one.

CComment ccomment = getCommentById(11801); string oldComm = ccomment["text"]; string newComm = oldComm + "\nEditing the comment"; return editComment(11801, newComm);

See also