Author Topic: How to apply stereotype from toolbox to package?  (Read 493 times)

Arquesoft

  • EA User
  • **
  • Posts: 68
  • Karma: +0/-0
    • View Profile
How to apply stereotype from toolbox to package?
« on: December 03, 2015, 02:44:15 am »
I created a Profile which includes different stereotyped elements. They belong to a custom toolbox and applies to UseCases and Packages.

If I want to apply the stereotyped element to a previously created Use Case, I can drag the stereotyped element from my custom toolbox while pressing Ctrl over the old Use Case. This result on the creation of some predefined tag values for the old Use Case (defined in the profile).

But, when trying to do the same on a package, the drag + ctrl over a previously created package results on a prompt asking for a new package name and not applying de stereotype to the package.

Same way if not dragging pression Ctrl even if in the prompt "apply/create new" I select apply.

I have 100 packages previously created to apply a stereotype pretending to have the tagged values created. Any advice in how to do it easily?

(I already did the same to 100 use cases manually and took no more than 5 minutes)

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 7799
  • Karma: +169/-21
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: How to apply stereotype from toolbox to packag
« Reply #1 on: December 03, 2015, 03:24:09 am »
You could write a script to add the stereotype to the packages, and then use the Element.SynchTaggedValues() operation to make sure the tagged values are created correctly.

Geert

Arquesoft

  • EA User
  • **
  • Posts: 68
  • Karma: +0/-0
    • View Profile
Re: How to apply stereotype from toolbox to packag
« Reply #2 on: December 03, 2015, 03:31:37 am »
Thanks! I haven't noticed this method!