testtrackchanges.docx (13.2 KB)
Hi,
we are able to find a track change/revision text. but is there a possibility to find the whole word in which the trach change exists?
if we see in the above screen, “jj” is a deletion and “gg” is an insertion. but how can we get the word “Suggestion” which has a trach change “jj” deletion.
Thanks,
Srihari Dande.
@haridande There is no concept of “word” in MS Word document, all textual content is represented by Run
nodes. each Run
node can have it own formatting. See our documentation to learn more about Aspose.Words Document Object Model. For example, in your document the nodes structure is the following:
So to get the word “suggestion”, you should concatenate parts of 4 runs, ignoring the deleted one.
Thank you for the quick reply @alexey.noskov.
but if we concatenate 4 parts, it will become the whole paragraph, not the “suggestion” word. but for my requirement, I need to find the word “suggestion” (the word in which the actual track change exists).
Thanks,
Srihari Dande.
@haridande You should concatenate not whole Run nodes text, but parts. You can consider whitespaces as a word separators.