Create and update custom xml part
- This topic has 2 replies, 3 voices, and was last updated 9 years ago by .
Viewing 2 posts - 1 through 2 (of 2 total)
Viewing 2 posts - 1 through 2 (of 2 total)
- You must be logged in to reply to this topic.
Home › Forums › Open-Xml-Sdk-JavaScript › Create and update custom xml part
Tagged: open xml js - custom xml part
Hi Vimal,
This is certainly doable. The Open-Xml-Sdk-Js is somewhat similar to the classes in System.IO.Packaging, in that you can create any variety of part, with any content type, and create a relationship to that part from the main document, or from any other part.
You have to remember that when creating a custom XML part, you must actually create two parts – there is the part that contains your XML, and that part has a relationship to a properties part. Take a look at a document that contains a custom XML part using the Open XML Package Editor in Visual Studio, in order to see the content type for the custom XML part, and the content type for the properties part, and the various relationship types. Then your job in the Open-Xml-Sdk-JavaScript is to create those same parts, with the same content types, and with relationships with the same relationship types.
-Eric