Book a Demo

Author Topic: Shape Script - Query Shape if it has Associates Files  (Read 3608 times)

Paul Vermette

  • EA Novice
  • *
  • Posts: 13
  • Karma: +0/-0
    • View Profile
Shape Script - Query Shape if it has Associates Files
« on: January 24, 2019, 07:21:53 am »
Hey,

I am trying to create a decoration for an element using Shape Script. I want to create a visual indicator for an element "if" is has any "Associated Files" ( https://sparxsystems.com/enterprise_architect_user_guide/14.0/modeling_tools/associatedfiles.html ).

I didn't see any specific attributes related to this. Is there a specific property name I can use or something?

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +397/-301
  • I'm no guru at all
    • View Profile
Re: Shape Script - Query Shape if it has Associates Files
« Reply #1 on: January 24, 2019, 08:10:05 am »
I guess you need an add-in for that, implement it and call EXEC_ADD_IN (I never remember the underlines/EA-prefixes) from within the script.

q.

P.S. It's
Code: [Select]
hasproperty('addin:myAddIn,function','parameter') Check the help for hasproperty.
EXEC_ADD_IN is for this dreaded transformation script language.
« Last Edit: January 24, 2019, 08:13:50 am by qwerty »

Paul Vermette

  • EA Novice
  • *
  • Posts: 13
  • Karma: +0/-0
    • View Profile
Re: Shape Script - Query Shape if it has Associates Files
« Reply #2 on: January 24, 2019, 08:50:57 am »
I am just using the MDG builder with no code.... ugh...

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +397/-301
  • I'm no guru at all
    • View Profile
Re: Shape Script - Query Shape if it has Associates Files
« Reply #3 on: January 24, 2019, 09:55:31 am »
Not sure if Geert's EA-Addin tool can help here (where you can use internal EA scripts to be called like an add-in).

q.

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Shape Script - Query Shape if it has Associates Files
« Reply #4 on: January 24, 2019, 03:42:31 pm »
Not sure if Geert's EA-Addin tool can help here (where you can use internal EA scripts to be called like an add-in).

q.
Not really, it requires an add-in function to be called, and i didn't expose a general "call a script function" method in the add-in.

Geert