Book a Demo

Author Topic: Table sub-rows and DocumentGenerator.DocumentCustomData  (Read 2875 times)

Uffe

  • EA Practitioner
  • ***
  • Posts: 1859
  • Karma: +133/-14
  • Flutes: 1; Clarinets: 1; Saxes: 5 and counting
    • View Profile
Table sub-rows and DocumentGenerator.DocumentCustomData
« on: February 14, 2020, 11:23:49 pm »
Hello hdocument hackers,


I'm working with the DocumentGenerator and I want to create a table where a couple of the columns have sub-rows -- or put another way, some of the cells in a row are split vertically.

Let's say there are two columns in my main table. The first column is to contain element names, and the second the names of the connectors going from the element. These connector names should be in separate cells (what I call sub-rows), but looking at the main table, the whole set of connectors should be in the same row of as the element.

My question is: is there a way to construct
a) a document template, and
b) an XML tree that EA will understand?

Normally, the data passed to DocumentGenerator.DocumentCustomData contains a number of <Row>s, each with a number of custom-named elements which EA matches to the custom fields in the template. But is it possible for one of those XML elements to be another <Row>?
Code: [Select]
<Row>
    <Element>ElementName</Element>
    <Row><Connector>FirstConnector</Connector></Row>
    <Row><Connector>SecondConnector</Connector></Row>
</Row>

Sort of thing?

TIA,


/Uffe
My theories are always correct, just apply them to the right reality.

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Table sub-rows and DocumentGenerator.DocumentCustomData
« Reply #1 on: February 15, 2020, 03:43:58 am »
I don't think so.

I think the only option you have (if you really want this) is to create a document fragment, where you craft and return the RTF code yourself.

Geert