Book a Demo

Author Topic: EA 11: headers in API-generated document from MDG  (Read 3438 times)

Uffe

  • EA Practitioner
  • ***
  • Posts: 1859
  • Karma: +133/-14
  • Flutes: 1; Clarinets: 1; Saxes: 5 and counting
    • View Profile
EA 11: headers in API-generated document from MDG
« on: April 30, 2015, 10:25:40 pm »
Hey everyone,


Got a lot of ducks here that need lining up.

I'm generating a .docx document using a script. The script and the templates are in an MDG Technology, and everything is working except one thing -- headers.

Adding headers to my regular templates does zip. EA ignores them. (Unless I put them in the template fragments, in which case some but not all of the fragments cause the header to appear in the middle of the page, some but not every time that fragment is invoked.)

I can get headers by creating a linked document, which has the header but is otherwise empty, and calling Document.InsertLinkedDocument(). OK good.

But. InsertLinkedDocument() takes a GUID, which it uses (it would appear) to look up the linked document in t_document -- in the target project. I want to include the header document in the MDG Technology.

I've tried creating a linked document template in the MDG Technology project's resources, and including that with the MDG Technology, but referring to its GUID doesn't work -- presumably that's not included in the XML file, or otherwise EA doesn't check the MDG Technology to look up the linked document.

Is there a way to get this to work? Or am I going to have to place a copy of the header document in each target project?

Cheers,


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