By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,197 Members | 1,205 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,197 IT Pros & Developers. It's quick & easy.

Word document creation in XML

P: n/a
Hi All,

I'm pretty new to .Net, not to mention XML, so I truly appreciate any advice!

I have user data that I want to selectively insert into a MS Word document
in XML. Given the various content, I want to create a new instance of an XML
document and write the data to the XML doc using the Word ML schema. The key
item is that I want to be able to add content line-by-line or
section-by-section, to the word document using the XML schema. The reason
behind this is that the content will change dramatically.

The question comes down to this -- are there already-defined components that
allow me to write data in Word ML format to an XML file, or do I need to hand
code it to write specific tags (e.g. <w:pPr ..., <w:rFonts ....)?
Additionally, can I write this new XML file directly to a SQL 2005 database
with a "XML" data type field?

Everything I've found is focused on taking a doc binary file and converting
to XML, but I want to take data and insert it, section by section, into an
XML document that MS Word will open and apply the word schema. Essentially
this comes down to "building a word document, server-side, based on user
input in a web form, as an XML file". I need this to be XML because the data
will eventually
be used by other applications.

Recommendations on books, articles, etc. are also greatly appreciated!
Mar 15 '06 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.