Advertisement


How do I get InDesign to import XML into table cells?


Question

First, let me preface by saying i've read through James Maivald's Designer's Guide to InDesign and XML, but i'm still really confused.

I have an XML document that looks like:

<foo>
<bar>
    <one>1234</one>
    <two>5678</two>
    <three>9101112</three>
</bar>
(multiple more bar elements)
</foo>

In an ideal world, I would be able to import this document into InDesign with the following "table"

| Alpha | (one's value) |
| Beta  | (two's value) |
| Delta | (three's value) |

With the tables repeating, of course.

I can't seem to find a good guide to making this work - even basic XML import was a little challenging, though I finally got that working. Do I need to use XSLT to transform the document into an equal number of cells, or can someone tell me what I need to complete the process? Is there a better reference for XML in InDesign that specifically covers table shenanigans?

2013/03/17
1
3
3/17/2013 8:07:00 PM

Tables are out of the iterative logic for both datamerge and XML import. They have their own structure that you must supply as is. You can't expect to build your table just because you have iterative data. Alas, it's not working like this.

So you have to generate a table structure with specific attributes. Look at this pdf from page 6 to page 7.

http://www.indesignusergroup.com/chapters/brisbane/files/643/Brisbane_Handout.pdf

Hope it helps,

Loic

2013/03/18
1
3/18/2013 9:14:00 AM