Category / Section
To know which of the connectors are connected to the node
1 min read
Edges Information
In our diagram control, we can use Node’s Edges/EdgesLeaving/EdgesEntering properties to know which of the connectors are connected to the current node.
Properties | Descriptions |
Edges | To get all the connectors to connected with the node |
EdgesLeaving | To get all the connectors which are leaving from the nodes |
EdgesEntering | to get all the connectors which are entering to the nodes |
Please refer to the below code example.
Code example:
[C#]
Ellipse ellipse = new Ellipse(20, 20, 100, 100); diagram1.Model.AppendChild(ellipse); //To get all the connectors to connected with the node... NodeCollection edges = ellipse.Edges as NodeCollection; //to get all the connectors which are entering to the nodes... NodeCollection edgesEntering = ellipse.EdgesEntering as NodeCollection; ///To get all the connetors which are leaving from the nodes... NodeCollection edgesLeaving = ellipse.EdgesLeaving as NodeCollection;
[VB]
Dim ellipse As New Ellipse(20, 20, 100, 100) diagram1.Model.AppendChild(ellipse) 'To get all the connectors to connected with the node... Dim edges As NodeCollection = TryCast(ellipse.Edges, NodeCollection) 'to get all the connectors which are entering to the nodes... Dim edgesEntering As NodeCollection = TryCast(ellipse.EdgesEntering, NodeCollection) '''To get all the connetors which are leaving from the nodes... Dim edgesLeaving As NodeCollection = TryCast(ellipse.EdgesLeaving, NodeCollection)