XML to Word Schema?

Hi there,

is there a XML Schema for Aspose.Words or something like that describing the DOM? Similiar to the one for Aspose.PDF: https://products.aspose.com/pdf/
Background:
I got a XML file (validating against the PDF Schema) that is to be converted to DOC.
I browsed the online-docs, but only thing i found was Mailmerge and WordProcessingML, but its not exactly what im looking for.
I hope im just to ignorant and somebody can enlighten me
Greetz,
Jens

Hi Jens,

Thanks for your inquiry.

I’m afraid only very old versions of Aspose.Words provide the ability to save a document in the Aspose.Pdf XML format. This format was removed and replaced by our own rendering engine which renders the documents to PDF without the use of Aspose.Pdf. Could you please explain further why do you need the XML format?

Best Regards,

Hello,
thanks for your reply.
I think there is al little misunderstanding, we have XML and want DOC
Our application generates a XML file that is to be converted to a Word Document and other target formats. One format is PDF, here we use Aspose.PDF via XML schema to create a PDF from our XML file.
My question is: can I use a similar solution to convert our XML into a Word Document?
(XML --> Word)
If yes, is there a XML schema describing the XML Aspose.Words could use to convert to DOC?
Greetz, Jens

Hi Jens,

Thanks for the additional information. Could you please attach your XML file, you want to convert to DOC format, here for testing? I will investigate the issue further on my side and provide you more information.

Best Regards,

Thanks for your quick reply!
As our application is still in development, so is the XML design for our templating system.
We are developing a XML design suiting Aspose PDF and Words input format if possible, supporting only basic features.
How should an XML file to be formatted, that Aspose can convert it to Doc and Docx?
(In your product information on your website, XML has been mentioned as an input format for Aspose.Words, and now thats what I’m searching for )
Greets,
Jens

Hi Jens,

Thanks for your inquiry and sorry for the delayed response. No, you can not open a simple XML file using Aspose.Words component. However, Aspose.Words provides exhaustive support for different XML-based formats for word processing documents e.g. OOXML, Flat OPC and also Word 2003 XML. For more details, please visit the following link:
https://docs.aspose.com/words/net/supported-document-formats/

Please let us know if you need more information, we are always glad to help you.

Best Regards,

Hi Jens,

Awais is absolutely correct in this case, Aspose.Words only supports XML formats based on the Microsoft Word format.

I can provide some other suggestions though:

  • Use a word document to create your template and then convert it to DOC, DOCX or PDF (all are supported by Aspose.Words) without using XML or Aspose.Pdf. Is there any reason why you need to use Aspose.Pdf?
  • Create an XML file and load that using Aspose.Pdf then convert that document to DOC using Aspose.Pdf (only the .NET version has support for this currently)
  • Assuming you are only creating basic XML templates for Aspose.Pdf, write your own quick reader code which uses XmlDocument to read each element of the Aspose.Pdf XML and creates a new word document using Aspose.Words from it. Each element would be translated into the “word document” equivalent and inserted using Aspose.Words.

Thanks,

Hi there,
thanks, creating from XML in PDF and save to Doc would be nice, so we could use the same base XML for both outputs. But we’re working with Java.
Best solution for us would be your last suggestion, to load the XML and fill the new Word Document element by element.
We dont have to use PDF for doc-conversion, I just took it as an example workflow how i hoped it would work for word to.

Greets,
Jens

Hi Jens,

Thanks for the additional information.

Sure, please let us know we can help with anything else.

Thanks,