Dear Team,
We are trying to convert a Word document to Word xml and do some manipulation in this XML and then I convert word xml back to DOCX word . The feature is working but few of the sections are protected during this conversion and we are not able to edit the updated document. Request you to please help. Attaching the input word document and the code.
Note: - The input document has few sections protected but the resultant document is completely protected irrespective of the sections.
Convert Word to Word Xml :
Document doc = new Document(Server.MapPath("//input.docx"));
doc.Save(Server.MapPath("//output.xml"), SaveFormat.WordML);
Convert Word Xml to Word :
Document doc = new Document(Server.MapPath("//output.xml"));
doc.Save(Server.MapPath("//output.docx"), SaveFormat.Docx);
Thanks