1
Automation Interface, Add-Ins and Tools / Re: DiagramObjects.AddNew doesn't add a new diagramobject
« on: May 13, 2022, 06:32:14 pm »
I see. I tried that now but for some reason I still can't see a new row in the t_diagramobjects table.
You may be undoing your changes then by saving the diagram or something like that.
Make sure you don't do anything else after the diagramObject.Update() method and then look in the database.
See https://github.com/GeertBellekens/Enterprise-Architect-VBScript-Library/blob/master/Projects/Project%20M/Diagram%20Group/Add%20defaults%20from%20template%20diagram.vbs for an example script that adds elements to a diagram.
Geert
Thank you! It finally worked. It didn't show up until I also assigned diaObj.Sequence a value and then it worked. Thank you very much
Manuel