Book a Demo

Author Topic: Quickest way to open Linked Document Artifact from Traceability window  (Read 3527 times)

Jacob Vos

  • EA User
  • **
  • Posts: 108
  • Karma: +0/-0
    • View Profile
The situation: In Document Artifacts, several subjects are described. The Document Artifacts are all on one Diagram. Double clicking on a artifacts opens a 'main page' (don't know how to name it - it's a tab besides the tabs with diagrams).

Each Document Artifacts is connected to one ore more classes, dependent on the subject.

At selecting a class, the Traceability window shows the related Document Artifacts. Now I want to open the document concerned on a 'main page'. How to do this? The quickest way I found:
1. Right-click the Document Artifacts in the Traceability window;
2. Select 'Find in all diagrams';
3. Double-click the diagram;
4. Close the 'find diagrams' windows;
5. Double-click the selected Document Artifact.

Is there a quicker way?

Note that right-clicking in the Traceability window, then 'Switch to related element' and opening the Document windows is not an acceptable alternative, because there are hyperlinks in the document to other elements, and clicking those links will show the Document window with contents for that element.

Another work-around is to temporarily place the Document Artifact on the diagram on which the class is (by clicking in the Traceability window on 'Place element in diagram'). However this probaby won't work in the Sparx Lite version.

Uffe

  • EA Practitioner
  • ***
  • Posts: 1859
  • Karma: +133/-14
  • Flutes: 1; Clarinets: 1; Saxes: 5 and counting
    • View Profile
Hi Jacob,


First off, Document Artifacts are a special case of Linked Documents. The "main page" you're referring to is the RTF editor showing the linked document.
So in your case it's the document artifacts that have linked documents, not the classes.

There are essentially two parts of the process you describe: locating the relevant artifact, and then opening its linked document.
I can't see any way to address the first part, but you can speed up the second part significantly by using the "special action".

The special action is something you can do with a selected element, other than opening its regular properties dialog.
What exactly this special action is varies, but the special action for a document artifact is to open the linked document in the editor.
The special action is executed by selecting the element in the browser and either hitting shift-Enter or right-clicking and selecting Properties -- Special Action.

An element which has a linked document (ie your document artifacts) will also respond to the keyboard shortcut Ctrl-Alt-D by opening the document in the editor.
Personally I prefer this since it can be done one-handed and thus faster (and it's an unambiguous command, while the special action has different effects for different elements), but both methods work.

So you don't need to locate the artifact in its diagram to open it in the editor, you can do it straight from the browser.


I had a look, but I can't see a way to write a script which would open the editor directly from the class which has the trace connector to the artifact. This is because there isn't anything in the API to open the linked document. Create and delete, yes, but not open the editor.
So regardless of everything else, opening the linked document has to be done through the regular GUI.


Whether or not this will work in EA Lite I can't say, but it's easy to test. There was another thread recently where Sparx hinted that EA Lite is on its way out (there isn't a version 15) so word of warning.
The special action might have been introduced in 15, but if so the Ctrl-Alt-D shortcut should still work.

HTH,


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

Jacob Vos

  • EA User
  • **
  • Posts: 108
  • Karma: +0/-0
    • View Profile
@Uffe: Thx, this indeed speeds it up.

(And yes, I was aware of the 'chain' Class - Linked Document Artifact - Linked Document.)