Hii,
my code is
private void updateContentControl(Document document, DocumentBuilder documentBuilder, Map<String, TrackChange> contentControlIdToText, StructuredDocumentTag std) throws Exception {
std.removeAllChildren();
Paragraph para = new Paragraph(document);
std.appendChild(para);
documentBuilder.moveTo(std.getFirstChild());
document.startTrackRevisions(performedBy,performedDate);
documentBuilder.insertHtml(contentControlIdToText.get(std.getTag()).getModifiedText());
Node lastChild = std.getLastChild();
if (("\r").equals(lastChild.getText())) {
std.removeChild(lastChild);
}
document.stopTrackRevisions();
}
I want to get track changes only on the latest updated text into the document by the specific User. but In my above Code, I Don’t have the latest specific changed text which is inserted. so I am inserting all the Text with the newly inserted text in documentBuilder