wordpress hit counter
How can create a locked text ? - WordprocessingML - Formats - OpenXML Developer

How can create a locked text ?

Formats

Discussions about working with different Open XML Formats

How can create a locked text ?

  • rated by 0 users
  • This post has 2 Replies |
  • 0 Followers
  • Two problems here :
    1. I have a certain chunk of content for instance :
    <p><pPr>..<pPr><r>..</r></p><p>..</p> etc and I want to protect that chunk of content from user edit.
    Is there a special tag withwich I can surround that content such that the final result is locked ?

    2.I want to lock the whole document.
    Is there a global property I need to write in the docPr part for instance,etc ?

    Thank you in advance.





    Pure, high performance, unmanaged C++.
  • hINTModuleState:

    1. I have a certain chunk of content for instance :
    <p><pPr>..<pPr><r>..</r></p><p>..</p> etc and I want to protect that chunk of content from user edit.
    Is there a special tag withwich I can surround that content such that the final result is locked ?


    Put it in an Sdt (aka content control) - you can lock those.

    hINTModuleState:

    2.I want to lock the whole document.
    Is there a global property I need to write in the docPr part for instance,etc


    Probrably - in older versions of Word at least, you could make a document read only.  Do it, and then look at the resulting XML.

    cheers,

    Jason
    docx4j maintainer
  • For the 2nd question, you can create both read-only document and ordinary document by Word 2007, and use OpenXmlDiff tool to observe the differences. The main differences are:

    1. <DocSecurity> value in app.xml

    2. <w:edit> and <w:enforcement> value of <w:documentProtection> in settings.xml.

    Besides, i am interested in why you set this access limitation? is it related to document type(legal documents? finacial documents?) or content priority?  I just want to know the practical industry of Open Xml SDK if you are convenient to provide such information. Thanks in advance:)

Page 1 of 1 (3 items)