Book a Demo

Author Topic: Target object name as a source object tagged value  (Read 3646 times)

kpietrusewicz

  • EA Novice
  • *
  • Posts: 18
  • Karma: +0/-0
    • View Profile
Target object name as a source object tagged value
« on: August 28, 2020, 08:59:21 am »
Hi All,
Is it possible to create tagged value that is updated, based on the connected objects?

Example:
stereotype "class_01" connected with "class_02" by the relationship "relationship".
class_01 has tagged value TARGET - that is updated with the name of class_02 object when it is connected.

Is it simple or hard to implement?
PLS help.
Krzysztof

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Target object name as a source object tagged value
« Reply #1 on: August 28, 2020, 02:13:49 pm »
Have you tried a RefGUID tagged value.

Technically this holds the guid of the target element (and doesn't change at all) but EA shows the name of that target element in the properties/tags window.

Geert

Uffe

  • EA Practitioner
  • ***
  • Posts: 1859
  • Karma: +133/-14
  • Flutes: 1; Clarinets: 1; Saxes: 5 and counting
    • View Profile
Re: Target object name as a source object tagged value
« Reply #2 on: August 28, 2020, 04:04:35 pm »
Hello Krzysztof,


RefGUIDs work, as Geert suggests, and if you want multiple element references in the same tagged value you can use a RefGUIDList.

However, there is nothing to link a tagged value with a connector. So your class_01 could have a RefGUID tagged value containing (the GUID of) class_02, but that would be independent of whether there was a connector from class_01 to class_02, and you can't get the RefGUID tag to auto-update when the connector changes. Not without building an Add-In.

A different option from the tagged value might be to use a shape script to show the name "class_02" in class_01 if they are connected.
You can do that with a RelatedElement shape, described here. It's a little fiddly, so might not be worth the effort.

HTH,


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

kpietrusewicz

  • EA Novice
  • *
  • Posts: 18
  • Karma: +0/-0
    • View Profile
Re: Target object name as a source object tagged value
« Reply #3 on: August 29, 2020, 10:31:55 am »
Dear Geert, Dear Uffe,
I used RefGUID and RefGUIDList type of tagged values. I was thinking about having graphical connector (instead of referencing objects during modeling) with auto-updated tagged values in both source and target objects. It would help me with exporting theses data with CSV type of files.

Unfortunately I do not have enough knowledge for building such advanced tool :-( Also having this information shown with the use of ShapeScripts will not help me with my problem.

Thank You for Your kind and helpful answers. I wonder, if EA will do such functionality in next releases. It would be great.
Best regards,
Krzysztof

ps. Looks like it is time for learning Add-In building :-)

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Target object name as a source object tagged value
« Reply #4 on: August 29, 2020, 05:03:55 pm »
In this case a bit of SQL should suffice to create an SQL Search that you can then save as CSV.

That should be a fair amount quicker then building an add-in.

Geert