Sparx Systems Forum
Enterprise Architect => Automation Interface, Add-Ins and Tools => Topic started by: Clemo on July 15, 2014, 10:24:07 pm
-
Hi,
I just cannot seem to find the method to delete a diagram using the Java API, tried destroy() but seems to have no effect!
Can anybody point me in the right direction
Clemo
-
Hi Clemo,
diagrams are created and deleted in the context of the owned element. Here: Package or Elements may contain Diagrams. Details see at Attribute Diagrams (collection) in the API object reference.
You can add/delete diagrams on the collection of diagrams in Package or Elements. The command is: Delete(short index) or DeleteAt(shortIndex, refresh).
Thomas Kilians e-book ScriptingEA may be a good help to understand and master the EA API.
Helmut
-
Thanks Helmut.