Book a Demo

Author Topic: Hide name or type of ActivityParameter and Action Pins - MDG Diagram Profile  (Read 4024 times)

Julia_

  • EA Novice
  • *
  • Posts: 3
  • Karma: +0/-0
    • View Profile
I created a MDG and I want to hide either the name or the type of ActivityParameter and ActionPins per default in a stereotyped ActivityDiagram.
I already found the option to Hide the Stereotype of Elements in the Profile Helper - exists there something for type or name, too?
"hide Element Stereotypes" only works in ClassDiagrams and not in ActivityDiagrams - how can that be?

Thank you :)

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +397/-301
  • I'm no guru at all
    • View Profile
You need to add <<diagram property>> stereotyped attributes to your stereotype. These appear in the context menu as switches. In a shape script you can test the switch. Note that the name appears in the context menu and the alias is used for the test in the shape scipt (because you want not spaces in the name).

q.

Julia_

  • EA Novice
  • *
  • Posts: 3
  • Karma: +0/-0
    • View Profile
Thank you for your answer, but I do not now exactly what you mean.
Do I have to add stereotyped ActivityParameter and ActionPins (I wanted to Use the UML ones..)?
What do I have to type as attributes?

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +397/-301
  • I'm no guru at all
    • View Profile
Sort of. "<<diagram property>> Show Activity Parameter" with alias ShowActivityParameter in the stereotype.
Then in the shape script
Code: [Select]
if (HasProperty("ShowActivityParameter", "1")) {
  print("...");
}
This will make EA show "Show Activity Parameter" in the diagram element context menu with a tick mark. Just give it a try.