Reply to: Setting a document as read-onlyMarch 19, 2009 at 7:55 pm
Look at ReadOnlyContainer, another read/writeable property on Selection/Range objects. Setting it to true will make everything in that selection's container read-only.
Setting the WritePermittedContainer flag to true allows you to create “islands of writeable” inside read-only containers. In some quick testing just now, it looks like this can even be done *before* setting the read-only property on the outer container.
Both of these properties get reset throughout the document if you leave Normal/TagsOn view.
As for the beep, I'm not sure how to do that. Default behaviour is that XMetaL will display an alert when the user tries to type in a read-only area.