Book a Demo

Author Topic: Renaming a Model Transform Template  (Read 6961 times)

DanG83616

  • EA User
  • **
  • Posts: 180
  • Karma: +0/-0
    • View Profile
Renaming a Model Transform Template
« on: May 08, 2013, 03:23:48 am »
Is there a way to rename a model transform template? Also, how can I remove templates from a project?

I tried exporting the template, replacing the name (<template name>_Transform_Template) and importing. That doesn't work because there are many GUIDs that collide with the existing template.

I'd like to avoid creating an entirely new project just to change some bad template names.

Thanks,
Dan

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8110
  • Karma: +119/-20
    • View Profile
Re: Renaming a Model Transform Template
« Reply #1 on: May 09, 2013, 08:36:00 am »
The approach of the export will work if you delete the existing templates before re-importing.

DanG83616

  • EA User
  • **
  • Posts: 180
  • Karma: +0/-0
    • View Profile
Re: Renaming a Model Transform Template
« Reply #2 on: May 09, 2013, 11:10:25 am »
I couldn't figure out how to delete an existing template, either. I guessed that the only way to delete the template is to start a new project. Is there a way to remove a template from a project? It must be right in front of me by I don't see it...

Thanks,
Dan

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8110
  • Karma: +119/-20
    • View Profile
Re: Renaming a Model Transform Template
« Reply #3 on: May 09, 2013, 12:18:59 pm »
Quote
I couldn't figure out how to delete an existing template
The button near the bottom right labeled 'Delete' will delete the current template (or override of the default template)

DanG83616

  • EA User
  • **
  • Posts: 180
  • Karma: +0/-0
    • View Profile
Re: Renaming a Model Transform Template
« Reply #4 on: May 09, 2013, 02:59:20 pm »
I'm must be using the wrong words. The button on the lower right only affects individual custom templates. It does not seem to affect the built-in templates that EA creates when you create a new transform. How does one get rid of an entire transform?

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8110
  • Karma: +119/-20
    • View Profile
Re: Renaming a Model Transform Template
« Reply #5 on: May 09, 2013, 04:32:20 pm »
It will no longer exist if there are no templates associated with it.

DanG83616

  • EA User
  • **
  • Posts: 180
  • Karma: +0/-0
    • View Profile
Re: Renaming a Model Transform Template
« Reply #6 on: May 10, 2013, 02:08:04 am »
Okay! I finally got a transform deleted. Delete all the custom templates and any modified build-in templates (they'll still be there but Modified" will be "No"). EXIT the transform editor. The transform will be gone when you next open the editor.

The rename process is:
  • Export Reference Data->Model Transforms...
  • Use a text editor to find and replace the old name
  • Use the delete process above to rid yourself of the old transform
  • Import the renamed tranform

DanG83616

  • EA User
  • **
  • Posts: 180
  • Karma: +0/-0
    • View Profile
Re: Renaming a Model Transform Template
« Reply #7 on: May 10, 2013, 03:58:33 am »
There is one more little snag (well, could be big) to this. All the XRefs for elements previously created will have the old transform name as the "namespace" attribute. When you run the renamed transform, you'll get new elements. This is a problem if you are directly modifying derived elements (bad idea) or have created diagrams with them (seemingly, a good idea).

Cheers,
Dan

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8110
  • Karma: +119/-20
    • View Profile
Re: Renaming a Model Transform Template
« Reply #8 on: May 10, 2013, 08:44:09 am »
Then modify your TRANSFORM_REFERENCE calls to explicitly use your old template name.

eg.
%TRANSFORM_REFERENCE("Class", classGUID, "My Old Transform")%