Book a Demo

Author Topic: Generate script name  (Read 6390 times)

royvanmarrewijk

  • EA User
  • **
  • Posts: 61
  • Karma: +1/-0
    • View Profile
Generate script name
« on: September 15, 2016, 10:18:46 pm »
Hi,

We use JScript to write scripts that puts the content of the model into a word document. Now I would like to add the name of the script in the document so how can I access the name of the running script (and if possible the names of the included scripts).

Kind regards,
Roy

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +397/-301
  • I'm no guru at all
    • View Profile
Re: Generate script name
« Reply #1 on: September 15, 2016, 11:00:00 pm »
Since you wrote the script yourself you can hard code that, can't you?

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: Generate script name
« Reply #2 on: September 16, 2016, 12:42:35 am »
I don't think scripts are self-aware, so I doubt there's a way to find out which script is running.

Geert

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8626
  • Karma: +259/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: Generate script name
« Reply #3 on: September 16, 2016, 09:44:18 am »
Since you wrote the script yourself you can hard code that, can't you?

q.
Q is correct!  We even code process names within scripts/add-ins and log to tagged values against the item in the repository so we know which automaton, doing what, last touched the item.

Paolo
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

royvanmarrewijk

  • EA User
  • **
  • Posts: 61
  • Karma: +1/-0
    • View Profile
Re: Generate script name
« Reply #4 on: September 16, 2016, 05:36:12 pm »
Hi,

My idea was to automate the generation of the script name so I minimize the amount of administration. But no problem I'll understand that this feature doesn't exists.
Thanks for your reaction gents.

Roy