How protect part of the text using OnCheckProtection event?
Just readonly.
Not delete/edit part the text.
-
-
- Offizieller Beitrag
Hi, you need to apply the afsProtected attributes to the text you want to protect. Use property ProtectedProp to activate the protection.
OnCheckProtection can be used to overwrite protection. It is triggered every time
the protection status of a certain text element is checked.
The parameter CheckClearSelection is TRUE when the selected characters are checked. -
OK, thanks for your reply, but when i apply the afsProtected, all the text is protected.
I want protect just one PART that was previously defined
Ex: "The book is on the table."
PROTECT JUST THE WORD "BOOK". -
- Offizieller Beitrag
Hi,
If you select the word "book" and apply the character style using CurrAttr.AddStyle(afsProtected) then only the selected text is protected. This works just the same as applying the style afsBold to bale it bold.
Julian