Customization > Extensibility Through Profiles, Stereotypes, Tag Definitions and Scripts > Extensibility through stereotype scripts and script items > Working with profile diagrams > Creating a tag definition on a profile diagram
  
Creating a tag definition on a profile diagram
This topic provides information for creating a Tag Definition on a Profile Diagram. For other ways of creating a Tag Definition, see Creating a tag definition to extend linking capabilities and Creating a tag definition to extend model item properties.
You can create non-reference and reference Tag Definitions on a Profile Diagram.
To create a non-reference tag definition on a profile diagram:
1. On the Profile Diagram toolbar, click the Non-reference Tag button.
2. On the Profile Diagram, click the Stereotype for which you want to create the non-reference Tag Definition.
3. Type the name of the Tag Definition, and then press the Enter key.
* 
The Name has to be unique within the Model; spaces and underscores are ignored when checking the uniqueness of a Tag Definition Name.
You may experience problems if you apply a Tag Definition to an item and the Tag Definition's name matches an automation interface property name of that item.
If you want the display name of the Tag Definition in Modeler to be different from its real name: on the General tab of the Tag Definition's property pages, type an alternative name in the Name Alias box.
4. Open the Tag Definition's Property Pages.
5. Click the Type tab, and then select the appropriate type (not Reference). See Overview of extending linking capabilities through stereotypes and tag definitions and Overview of extending model item properties through stereotypes and tag definitions.
6. Click the Usage tab, set the options as required, click the Publish button, and then from the confirmation dialog click Yes.
7. If you want other Stereotypes to use the Tag Definition: on the Profile Diagram, drag the Tag Definition to those Stereotypes.
To create a reference tag definition on a profile diagram:
1. On the Profile Diagram, ensure that the following items are on shown:
The Stereotype that is to use the reference Tag Definition.
The Meta Model Types and Stereotype that are to be the target item of the reference Tag Definition.
2. On the Profile Diagram toolbar, click the Reference Tag button.
3. Click the source Stereotype that is going to use the reference Tag Definition.
4. Click the target Meta Model Type or Stereotype.
5. Type the name of the reference Tag Definition, and then press the Enter key.
* 
The Name has to be unique within the Model; spaces and underscores are ignored when checking the uniqueness of a Tag Definition Name.
You may experience problems if you apply a Tag Definition to an item and the Tag Definition's name matches an automation interface property name of that item.
If you want the display name of the Tag Definition in Modeler to be different from its real name: on the General tab of the Tag Definition's property pages, type an alternative name in the Name Alias box.
6. For each additional target Meta Model Type or Stereotype:
a. On the Profile Diagram toolbar, click the Reference Tag button.
b. Click the source Stereotype that is going to use the reference Tag Definition.
c. Click the target Meta Model Type or Stereotype.
d. On the popup menu, click the command for the Tag Definition you created.