Author Topic: RTF generation with images and tables  (Read 5576 times)

Eugen Wiebe

  • EA User
  • **
  • Posts: 20
  • Karma: +0/-0
    • View Profile
RTF generation with images and tables
« on: November 25, 2010, 11:05:53 pm »
(see also: http://www.sparxsystems.com/cgi-bin/yabb/YaBB.cgi?num=1290675492)

I have feature requests:
1. Make possible to add images to elements
2. Make possible to add tables

These should be correctly added to RTF document

Why? Because in our original SystemRequirementSpecifcation in Word images and tables are often used. And if you want to create a SRS now in EA and then export to RTF (to give e.g. to the customer or use internally) it should contain the same elements as in original document.

Or describe an alternative way how to do this.
Thanks.

skiwi

  • EA Expert
  • ****
  • Posts: 2081
  • Karma: +46/-82
    • View Profile
Re: RTF generation with images and tables
« Reply #1 on: November 26, 2010, 07:25:08 am »
I'm note clear where you want to be able to put tables and images.

If you mean in notes, then I have a lot of sympathy with your request, especially as notes let you paste such things into them, then cruelly just display the html! (a bug imho).

However both images and tables can be added using linked documents.
« Last Edit: December 13, 2010, 07:29:53 am by skiwi »
Orthogonality rules
Using EA16.1 (1627) on Windows 11 Enterprise/64 bit. Repositories in SQLServer2019 DB Schema 1558.
WebEA on Pro Cloud Server 4.2.64

Eugen Wiebe

  • EA User
  • **
  • Posts: 20
  • Karma: +0/-0
    • View Profile
Re: RTF generation with images and tables
« Reply #2 on: November 26, 2010, 10:03:16 pm »
OK, again.
I have several requirements, and in the original Word document, there are sometimes pictures or Word-Tables used to better describe a requirement.

So, now I want to create an EA project (I have already a template) and put all requirements in there, also the bitmaps and tables for each requirement.

Afterwards I would generate document as RTF and it should look like (or be similar to) original Word document.
It should for each requirement show the text of the requirement (Notes) and also the Table and image.

Through RTF template I can manage Notes, Alias ... of the requirement, but how is about image and table?
I dont want to set the appearance of the requirement diagram to an alternative image and there use the wished image.

I thought, it would be possible to insert (copy/paste) image and table to Notes of the requirement ... but it seems, it isnt.


I have also read:
http://www.sparxsystems.com/downloads/whitepapers/Working_with_the_RTF_generator.pdf
but it did not help.

Is there a way (or an other way) to add images and tables to RTF document for each element?

Eugen Wiebe

  • EA User
  • **
  • Posts: 20
  • Karma: +0/-0
    • View Profile
Re: RTF generation with images and tables
« Reply #3 on: December 01, 2010, 07:08:37 pm »

johann

  • EA User
  • **
  • Posts: 27
  • Karma: +2/-0
    • View Profile
Re: RTF generation with images and tables
« Reply #4 on: December 11, 2010, 02:25:34 am »
Hallo Eugen,

for a past project we tried to generate a Word document using RTF templates and document generation out of Enterprise Architect. We tried hard for several weeks, but ran into problems for several reasons:
  • The RTF templates you can build are very limited, there were many relationships between linked elements that we wanted to document, but that simply could not be expressed with a template.
  • there is no possibility to add images or tables to the content. You can place them in linked documents, but there was no way to embed these documents into the final document.
  • the final Word document suffered from broken formatting and needed manual post processing.

Finally, we gave up generating an Word document. EA is not a proper tool for this kind of output, and Microsoft Word makes all even worse.

Then we came up with the following solution:
We exported all packages of our model to XMI format. The images and tables in the linked documents where exported (in HTML format), too. Then we ran XSLT stylesheet on the XMI data that replaced the RTF templates and additionally integrated the content of the linked documents into the documents. The format of the resulting documents was XHTML that could be easily converted to PDF.

That worked great and produced the desired documents. But if it is done this way, one needs proficient knowledge in XML, XSLT and XHTML/CSS technology.

skiwi

  • EA Expert
  • ****
  • Posts: 2081
  • Karma: +46/-82
    • View Profile
Re: RTF generation with images and tables
« Reply #5 on: December 13, 2010, 07:30:40 am »
Quote
there were many relationships between linked elements that we wanted to document, but that simply could not be expressed with a template

For example ...
« Last Edit: December 13, 2010, 12:28:36 pm by skiwi »
Orthogonality rules
Using EA16.1 (1627) on Windows 11 Enterprise/64 bit. Repositories in SQLServer2019 DB Schema 1558.
WebEA on Pro Cloud Server 4.2.64

AndyJ

  • EA User
  • **
  • Posts: 337
  • Karma: +5/-3
  • It's only a model
    • View Profile
Re: RTF generation with images and tables
« Reply #6 on: December 13, 2010, 11:50:49 am »
Eugen,

Is it EA diagrams that you're trying to copy into your word documents?

If so, have a look at "copy RTF bookmark" in the help text.

Following Sparx's instructions, I'm creating RTF documents that contain all the material that I need in my Word documents.

In the Word documents, I have pasted links to "RTF bookmarks" that are embedded in the RTF file.

Provided that you add those bookmarks appropriately, you can update your Word documents to show new information with a few key presses...

i.e. F8 to generate an updated RTF (In EA)

Ctrl-A (Select all in Word)
F9 (Update all selected in Word)

Sun Tzu: "If you sit by the river long enough, eventually the body of MS Visio floats past."

johann

  • EA User
  • **
  • Posts: 27
  • Karma: +2/-0
    • View Profile
Re: RTF generation with images and tables
« Reply #7 on: December 14, 2010, 03:15:35 am »
hi skiwi,

..one example is the generation of a thorough traceability matrix of requirements/solutions/realisation/verification for the development of software for safety critical systems (as demanded by the standards document IEC61508).

regards
Johann