Page 1 of 1

readonly content in certain part of the docx file

PostPosted: Fri Dec 09, 2011 3:36 am
by vgunaselan
Hi,
I am new to docx4j,

i am wondering can i make certain parts of docx files as read only by password protection?

most of the document is editable, only certain parts we want to make it as read only to avoid accidental edits.,

Thanks
Guna

Re: readonly content in certain part of the docx file

PostPosted: Fri Dec 09, 2011 2:17 pm
by jason
In principle, you can do with docx4j whatever is supported by the Open XML formats (with the exception of the extension mechanism).

Word has a couple of features you might be interested in. One is in the Word GUI under "Protect document"; you can also put the bits you don't want edited inside content controls, and set them to be non-editable. Another related feature is "Information Rights Management"....

Once you have decided how you want to do it in Word, you can inspect the resulting docx, to see how it is implemented at the XML level (and hence, how you'd do it in docx4j - which is the point where this forum is best suited to help).