I am creating a simple Text Tagging Application using the Comments feature of RichTextEditor.
The functionality is very simple, User loads Text File in a RichTextEditor and Adds a Bunch of comments. There is nothing else the user can do. There is no formatting or images.
Once the user has done commenting, he can press a button to say "Complete". Now I want to know Each comment, the Text the user selected for commenting from the Original document, and the Ordinal position of the original selection in the document.
I was able to get all Comment objects, All CommentRangeStart and CommentRangeEnd objects along with the Span object which has the Text.
I am able to get what the user commented on what text. However I am not able to find the Position of the text in the original document. Please help.
CommentRangeEnd end = (CommentRangeEnd)start.End;
Comment comment = end.Comment;
Span textSpan = (Span)start.NextSibling;
positionOfText = ??
msgBoxString += comment.Author +
+ textSpan.Text +