ReadOnly SpanIndicator on last line

SyntaxEditor for Windows Forms Forum

Posted 9 years ago by Gareth Hayter
Avatar
I need the last line of a SyntaxEditor to be read-only. I created a read-only SpanIndicator but I can still enter text after the final character on the line ie: after the end of the SpanIndicator.

How can I ensure that it remains read-only right through to the end of the document?

Thanks,
Gareth.

Comments (2)

Posted 9 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
Hi Gareth,

For that scenario you may need to handle the DocumentPreTextChanging event and set e.Cancel to true if at the end of the document.


Actipro Software Support

Posted 9 years ago by Gareth Hayter
Avatar
Awesome - that works perfectly. Thank you.
The latest build of this product (v2020.1 build 0400) was released 24 days ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.