1
Automation Interface, Add-Ins and Tools / Re: first script to place a component on a diagram
« on: January 10, 2025, 08:44:37 pm »
Yes, thank you Geert.
This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.
function addElToDiag( element, diagram ) {
var diagObj as EA.DiagramObject;
var r = false;
let posL = 100;
let posT = 100;
diagObj = diagram.DiagramObjects.AddNew("l=100;t=100;", "");
diagObj.Update();
if (diagObj) {
diagObj.ElementID = element.ElementID;
diagObj.right = diagObj.left +100;
diagObj.bottom = diagObj.top +60;
diagObj.Sequence = 1;
diagObj.SetStyleEx("Selectable","1");
diagObj.SetStyleEx("Moveable","1");
diagObj.Update();
diagram.DiagramObjects.Refresh();
diagram.Update();
Repository.SaveDiagram(diagram.DiagramID);
Repository.ReloadDiagram(diagram.DiagramID);
r = true;
}
return r;
select ts.Stereotype stereotype, to2.Name, to2.Object_Type "type" from t_stereotypes ts
join t_xref tx on tx.Description like '%' || ts.ea_guid || '%'
join t_object to2 on tx.Client = to2.ea_guid
where ts.Stereotype like '%<Search Term>%';
<?xml version='1.0' encoding='utf-8' ?>
<xs:schema targetNamespace="eu.ngong.Check" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns="eu.ngong.Check" xmlns:ch="eu.ngong.Check">
<xs:element name="Check" type="ch:Check"/>
<xs:complexType name="Check">
<xs:sequence>
<xs:element ref="Check" minOccurs="1" maxOccurs="1"/>
<xs:element ref="Detail" minOccurs="0" maxOccurs="unbounded"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="Detail">
<xs:sequence/>
</xs:complexType>
</xs:schema>