Please note : This help page is not for the latest version of Enterprise Architect. The latest help can be found here.
Set Auto Naming and Auto Counters
When you create a new element in your model, you have different options for naming the element depending on how you are creating it. If you create the element:
• | On a diagram, the system applies a default naming convention of the element type plus the increment of the number of elements of that type in the same package - for example, Actor4; you can change this to any other name by editing the Name field on the element's Properties dialog |
• | Within the Project Browser, the system prompts you to type the element name into the New Element dialog |
You can also set up your own, automatic, naming and numbering convention for elements of the same type, so that:
• | On a diagram, it is your naming/numbering convention that is automatically applied to the new element (which you can still change if you need to, as before) |
• | Within the Project Browser, the New Element dialog Auto button applies the naming convention to your new element |
If you have existing elements in a package, and you want to apply the new naming convention to them, you can make this change very easily to all elements of the same type in the package at once (see Learn more, below).
You define a naming convention for the element type as a model setting. At the same time, you can also optionally define a naming/numbering convention for the Alias field for elements of that type.
Access Settings | Auto Names and Counters
Set up auto naming for an element type
Field/Option |
Action |
See also |
||||||
---|---|---|---|---|---|---|---|---|
Type |
Click on the drop-down arrow and select the element type to which to apply auto naming/auto numbering.
|
|
||||||
Name
|
||||||||
Prefix |
Type a prefix for the new name (optional).
|
|
||||||
Counter |
Type the counter value; use as many 0's as required to pad the number.
|
|
||||||
Suffix |
Type a suffix for the new name (optional).
|
|
||||||
Apply on creation |
Select the checkbox to apply auto naming to each new element of the specified type, on creation. If you do not select the checkbox, the autonaming details for the specified element type remain defined in the dialog, but are not applied to new elements of that type. The default element naming convention takes effect (<element type><n>).
|
|
||||||
Alias
|
||||||||
Prefix |
Type a prefix for the new Alias (optional).
|
|
||||||
Counter |
Type the counter value; use as many 0's as required to pad the number.
|
|
||||||
Suffix |
Type a suffix for the new Alias (optional).
|
|
||||||
Apply on creation |
Select the checkbox to apply Alias auto naming to each new element of the specified type, on creation. If you do not select the checkbox, the Alias autonaming details for the specified element type remain defined in the dialog, but are not applied to new elements of that type. The default element naming convention takes effect (<element type><n>).
|
|
||||||
Save |
Click on the Save button. New elements of this type now have an automatically-generated name and/or Alias with an incrementing counter value.
If an Alias is active, to view the Alias in a diagram requires that the option Use Alias if Available is selected in Diagram Properties.
|
Add Elements Directly To Packages
|
Notes
• | Automatic numbering - whether system default of user-defined - does not increment across package levels; if you have an element called Actor1 in Package A, and you create an Actor element in a child package of Package A, that Actor will also be Actor1 |
Learn more