Manipulating custom XML Data into a Word Document


  • I have an existing XML document which contains well-formed structural data in it. I need to find a way to retrieve data from this XML document and get values from the tags and output it into a word document.


    Additionally, I need to find a way to add new data into XML document or modify and delete existing ones.


    Using Word 2007, is there a way manipulating this XML document programmatically using VB, either back end Visual Basic Editor of Word 2007 or VS .NET?


    Any tutorials, samples, tips, or resources for this will definitely give me some good guidelines.


    Thank You.



    Monday, September 22, 2008 1:28 AM


  • Hi Adro


    Yes, it should be possible for you to work with the XML document in any of the three programming environments you mention. For the classic VB and Word VBA you'd need to import (Tools/References) the DLL (library) of an XML Parser. Microsoft distributes various versions of the Microsoft parser "Microsoft XML" with its applications. I think "Microsoft XML, v6.0" is distributed with Office 2007. If you decide to use Visual Studio .NET, then the XML capabilities come with the .NET Framework in the System.XML namespace.


    This forum is primarily targeted at the VSTO technology, so it's not the place to get help with learning or working with XML. The Please Read First message provides some links to other resources. Through the "all newsgroups" link you can get to the XML newsgroup (logically, it's very near the end of an alphabetical list!). If you decide to use .NET, then this is the forum for XML.


    Monday, September 22, 2008 8:00 AM