Book a Demo

Author Topic: Report Generation Webinars  (Read 24730 times)

MattAtRamsay

  • EA Novice
  • *
  • Posts: 12
  • Karma: +0/-0
    • View Profile
Report Generation Webinars
« on: October 28, 2025, 11:15:08 pm »
Hello
Phil Chudley did a great "Back to Basics" webinar on document generation from EA back in 2022. Take a look: https://www.youtube.com/watch?v=HgPjLvoTzpk
I'm looking for the next step - how to use template selectors and fragments was covered briefly, but following it using 17.1 (and 17.1's help) things are not behaving as they should. Any more comprehensive webinars available on this?
Thanks in advance!
Matt

philchudley

  • EA User
  • **
  • Posts: 750
  • Karma: +22/-0
  • EA Consultant / Trainer - Sparx Europe
    • View Profile
Re: Report Generation Webinars
« Reply #1 on: October 29, 2025, 12:06:29 am »
As the presenter of the webinar, many thanks for your feedback.

If you could be a bit more specific as to the issues you are facing in EA v 17.1 I will do my best to help you out.

Phil C
Models are great!
Correct models are even greater!

MattAtRamsay

  • EA Novice
  • *
  • Posts: 12
  • Karma: +0/-0
    • View Profile
Re: Report Generation Webinars
« Reply #2 on: October 29, 2025, 07:57:02 am »
Hi Phil

Thank you for the direct response - that really wasn't expected! Well, as usual, you did a great Webinar. I encourage others to check it out.

Going back over it, template selectors and template fragments were only briefly touched upon at the end. I also note that last year someone reported on the Youtube feed that these feature "do not work". They must, of that I am sure. However, after much experimentation, I can't repeat the successes others may have had.

It is so hard to respond to the "be more specific" as I'll have to go over the many things I've tried that do not work. Whereas, if there was a sample model and template using them where they do work - so I can repeat a single success - I think we may be progressing smoothly.

Anyone know of any samples and templates that demonstrate the practical and successful application of template selectors and template fragments?

Meanwhile, I found this in the webinar library from May 2023: "Model Publishing", https://sparxsystems.com/resources/lectures/show-video.html?video=model-publishing. Although very high level, it raised my eyebrows as it specifically referred to Master Documents at 14m:59s which only 2 years on are said to be deprecated and virtual documents are the answer (which I have been trying but getting limited success with). The next slide at 15:03 shows what I want to achieve, and refers to linked document templates for static content. I can see this working but it is unclear what they are (I guess a template that lifts linked documents out of elements) nor whether it is in conjunction with Master Documents or something else again. 

All the best, Matt
« Last Edit: October 29, 2025, 03:54:05 pm by MattAtRamsay »

MattAtRamsay

  • EA Novice
  • *
  • Posts: 12
  • Karma: +0/-0
    • View Profile
Re: Report Generation Webinars
« Reply #3 on: October 30, 2025, 07:18:00 pm »
Update:
Found this Sparx Webinar on Custom Documents, which opened my eyes to the value of custom documents and the sample models.
https://sparxsystems.com/resources/webinar/release/ea16/documentation/show-video.html

I've been working through the samples and found the use of template fragments, but am at a loss to see how the selectors work.

So my plan is to drop the perfect, deliver a custom document, and maybe learn the more detailed ropes over a longer span.

If this seems defeatist, this is what we're confronted with:
https://sparxsystems.com/enterprise_architect_user_guide/17.1/model_publishing/define_a_template_selector.html
That reference states:
Quote
Access
Use one of the methods outlined here to display the 'Custom Query' page of the 'Document Options' dialog. Before you select the Document Options icon, select the 'Custom' checkbox in the 'Sections' list, to enable the  'custom >   <custom' tags. These are necessary for the Template Selector fragment to work.

Ribbon
Publish > Model Reports > Templates : <select a fragment template> :  (Document Options icon) > Custom Query
Keyboard Shortcuts
F8 > Templates | Fragments | Double-click on <Fragment name>, then  (Document Options icon) > Custom Query
The Ribbon one does not represent what I'm seeing (V17.1 latest), and F8 inserts a black highlighted line in the template.
« Last Edit: October 30, 2025, 07:38:40 pm by MattAtRamsay »

philchudley

  • EA User
  • **
  • Posts: 750
  • Karma: +22/-0
  • EA Consultant / Trainer - Sparx Europe
    • View Profile
Re: Report Generation Webinars
« Reply #4 on: October 30, 2025, 08:45:08 pm »
Hi Matt

Essentially a Template fragment works in two modes
  • "normal template fragment" use the selectors as you would do normally
  • "script or query driven" template only use custom as the selector

Personally I only ever use script driven fragment using JavaScript to extract the Custom Fields into XML ready for insertion into other template(s).
The Custom Fields are user named and are the names of variables returned in the JavaScript.

The same technique also applies to SQL Driven scripts (which I have not used)

For a "normal template fragment" I would try the following:

Let's assume  that the Template Fragment extracts details for a Use Case Element. Then the selectors for the template fragment would be
Package
           Element

(Child packages if you want as well)

Add text, and fields as usual.

Invoke your template fragment in your "master template" within the element section. When the template is called, the element ID will be passed to the template fragment.

Hope this helps

All the best

Phil

Models are great!
Correct models are even greater!