Fog Creek Software
Discussion Board

XML -> Word

Does anyone know how it might be possible to link data which is in an XML document into a Word document? I don't want to just read the XML doc in Word, what I would like to do is, say, have a table or something in my Word doc which I can say "actually this column refers to that item in the XML document over there, and this other column refers to that other data". You can definitely present XML data in different ways, for example using Cocoon to present the data as HTML or WML, or PDF, and I suppose I want to do something pretty similar, but in my case one of the presentation methods is a Word document.

I was thinking that in this way I would really get a "living" document (just change your data in the XML doc, which implies that the XML doc is linked into the Word doc, not just the data imported) and you could share the data for different reasons, not just for use in the Word document. I thought Insert Hyperlink might work, but I can't seem to make it refer only to a specific area of the XML doc.

Anyone got any experience with this kind of thing?

Thursday, April 22, 2004

Word 2003 now has native XML support... go find the schema for it somewhere and then you can create your own docs.

James 'Smiler' Farrer
Thursday, April 22, 2004

Sounds like you need an XML ODBC datasource, you could then insert an Excel sheet which queried the datasource. I know Crystal Reports had an XML ODBC driver, I'm not sure if there are any others about though.

Tony Edgecombe
Thursday, April 22, 2004

Tony - you mean embed Excel sheets into the Word document?

Thursday, April 22, 2004

*  Recent Topics

*  Fog Creek Home