This is a migrated thread and some comments may be shown as answers.

Can't insert text between two PermissionRanges?

1 Answer 15 Views
RichTextBox
This is a migrated thread and some comments may be shown as answers.
Charles
Top achievements
Rank 1
Charles asked on 22 Feb 2012, 08:32 PM
Hi

Not sure if I'm being thick here, but I can't figure this out after hours of trying.

If I have two Permission Ranges (I assume it applies to most other annotations, but this is what I've been using). 

They appear on the page like this, separated by a carriage return:

[Range 1]
[Range 2]

If I set the Document Position inside Range 1, and use "MoveToNext()", it moves straight from one span into the next.  I'm trying to insert something in-between the two, and I'm finding it impossible for the Document.Insert() not to end up inside one of the PermissionRanges!

Any pointers appreciated!

Charlie

1 Answer, 1 is accepted

Sort by
0
Charles
Top achievements
Rank 1
answered on 22 Feb 2012, 08:52 PM
Forget it - always the way, after hours of trying, I write on here and work it out.  I don't think what I wrote above is accurate - MoveNext does get you the paragraph symbol in its own span.  I had some other code that was giving me the wrong positions...   
Tags
RichTextBox
Asked by
Charles
Top achievements
Rank 1
Answers by
Charles
Top achievements
Rank 1
Share this question
or