Changing an Element's Type
IntermediateCreated a node or relationship with the wrong type? Change it in place: it keeps its name, description, tags and diagram positions, and Metapad tells you up front if anything would be lost.
Sometimes an element ends up with the wrong type: a Team that is really a Department, or a relationship drawn as supports that should be realizes. You don't need to delete it and start over. Changing the type keeps the element itself, so its links in documents and its place on every diagram stay as they are.
Change the type
- One element: select it, then in the Properties panel click the type at the top and pick the new one.
- From a menu: right-click the element on the canvas or in the Model Navigator and choose Change type…, pick the new type and click OK.
- Several nodes at once: select them, right-click one of them and choose Change type…. All selected nodes of the same type as the one you clicked are changed together.
What is kept
- The element's name, description, tags and its position on every diagram.
- Property values whose property has the same name and data type in the new type. Translations come along too.
- Relationships that the metamodel still allows with the new type.
What Metapad asks you about
If nothing would be lost, the type changes straight away and you see Type changed to …. Otherwise a dialog lists exactly what would happen:
- relationships that the new type does not allow and that would be removed;
- property values that have no place in the new type and would be discarded;
- an ID that would be renumbered or removed.
Click Change anyway to go ahead, or Cancel. Either way, one Undo (⌘/Ctrl+Z) brings everything back: type, values, ID and removed relationships.
Tip: If a relationship would be removed unexpectedly, the metamodel is probably missing an Allowed Connection for the new type. Add it first, and the change goes through without losing anything.
IDs
If the new type numbers its elements (e.g. DEPT-), the element gets the next free number of that type. If both types share one numbering through inheritance, it keeps its number and only the prefix changes. If the new type has no IDs, the ID is removed.
When a change isn't possible
Metapad refuses the change, and says why, when:
- a simulation agent or link is bound to the element (detach or delete it first);
- for a relationship, the new type doesn't allow a connection between its two ends;
- the ID it would get is already taken.
When several elements are selected, the ones that can't change are skipped and the dialog says how many.
Next steps
- Setting Up Allowed Connections — make a type change lossless
- What are Allowed Connections? — the rules behind which relationships survive
This content was written collaboratively with AI.