Réserver une Démo

SVP notez : Cette page d’aide n’est pas pour la dernière version d’Enterprise Architect. La dernière aide peut être trouvée ici.

Pré. Proc.

EA_OnPostNewDiagramObject

EA_OnPostNewDiagramObject notifies Add-Ins that a new object has been created on a diagram. It enables Add-Ins to modify the object upon creation.
This event occurs after a user has dragged a new object directly from the Browser window or from the 'Resources' tab of the Browser window onto a diagram. The notification is provided immediately after the object is added to the diagram.

Syntax

Function EA_OnPostNewDiagramObject (Repository As EA.Repository, Info As EA.EventProperties) As Boolean
The EA_OnPostNewDiagramObject function syntax contains these parameters.

Parameter

Type

See also

Repository

EA.Repository
Direction: IN
Description: An EA.Repository object representing the currently open Enterprise Architect model. Poll its members to retrieve model data and user interface status information.
Repository Class

Info

EA.EventProperties
Direction: IN
Description: Contains these EventProperty objects for the new element:

  • ID: A long value corresponding to the ElementID of the object that has been added to the diagram

  • DiagramID: A long value corresponding to the DiagramID of the diagram to which the object has been added

  • DUID: A string value for the DUID; can be used with Diagram.GetDiagramObjectByID to retrieve the new DiagramObject

EventProperties Class

Return Value

Return True if the element has been updated during this notification. Return False otherwise.

Learn more