Da bietet sich der Absatz Schutz an:
call.ASet(WPAT_ParProtected, 1);
Diesen schutz muss man noch aktivieren:
WP.ProtectedProp := WP.ProtectedProp + [ppParProtected];
Dies sind die flags:
TProtectProps = (
ppParProtected,
// the complete paragraph cannot be deleted --> WPAT_ParProtected
ppCheckAllText, // Trigger event for the complete text
ppAllExceptForEditFields,
// Only allow editing in edit fields. Cursor jumps between edit fields
ppNoNewParagraphsInEditFields,
// Do not allow par insertion/deletion in EditFields
ppProtected, // Text with the style afsProtected cannot be overridden
ppHidden, // Text which uses the style 'hidden'
ppIsInsertpoint, // Protect the field start or end markers (wpobjMergeField)
ppIsMergedText,
// used to be 'ppAutomatic', The oposite of ppAllExceptForEditFields
ppIsBookmark, // Protect the bookmark start or end markers (wpobjBookmark)
ppIsTextObject, // Protect the fields (such as PAGE numbers) (wpobjTextObj)
ppIsImageObject, // Protected the images (wpobjImage)
ppProtectionTextObjects, // WPTools 7: used with TWPTextObj.Mode 'wpobjWithinProtected'
ppIsInvisible, ppAllowEditAtTextEnd, // Allow typing at text end
// These flags are not checked in "function TWPRTFEngineBasis.IsProtected()"
ppProtectSelectedTextToo,
ppProtectSelectedWholeTextToo, // Also protect text if whole text is selected
// Must be combined with ppProtectSelectedTextToo
ppDontProtectAttributes,
// V5.15 - if defined it is possible to change the attributes of protected text
// ppDontCopyProtectedAttribute - obsolte, see ClipboardOptions
ppDontUseAttrOfProtected,
// do not use the charattr if the text is protected
ppNoEditAfterProtection,
// Do not allow editing at the end of the paragraph if the last char is protected
ppInsertBetweenProtectedPar,
// Allow the insertion between protected paragraphs
ppIsTextObjectCustom, // Protect the fields, but not "PAGE", "NUMPAGES"
// obsolete: ppNotUsedForSpellAsYouGo // any text which is protected is not spellchecked!
ppBookmarkKeepStructure,
// Used with ppIsBookmark. Recreate Bookmark structure
ppInsertpointKeepStructure,
// Used with ppIsInsertpoint. Recreate Field structure
ppIsHyperlink,
// Protect the hyperlink start or end markers (wpobjHyperlink)
ppNoEditBeforeProtection
// Disable insertion if protected text is first in paragraph
);
Alles anzeigen