Articles in this section
Category / Section

To know which of the connectors are connected to the node

4 mins 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 node

EdgesEntering

To get all the connectors which are entering to the node

 

 

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 connected with the node... 
NodeCollection edges = ellipse.Edges as NodeCollection; 
 
// To get all the connectors which are entering the node... 
NodeCollection edgesEntering = ellipse.EdgesEntering as NodeCollection; 
 
// To get all the connectors which are leaving the node... 
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 connected with the node... 
Dim edges As NodeCollection = TryCast(ellipse.Edges, NodeCollection)
 
'To get all the connectors which are entering the node...
Dim edgesEntering As NodeCollection = TryCast(ellipse.EdgesEntering, NodeCollection)
 
'To get all the connectors which are leaving the node...
Dim edgesLeaving As NodeCollection = TryCast(ellipse.EdgesLeaving, NodeCollection)

 

Conclusion

I hope you enjoyed learning to know which of the connectors are connected to the node.

You can refer to WinForms Diagram feature tour page to learn about its other groundbreaking feature representations and documentation, and how to quickly get started for configuration specifications. You can also explore our WinForms Diagram example to understand how to create and manipulate data.

For current customers, you can check out our components from the License and Downloads page. If you are new to Syncfusio, you can try our 30-day free trial to check out our other controls.

If you have any queries or require clarifications, please let us know in the comments section below. You can also contact us through our support forumsDirect-Trac, or feedback portal. We are always happy to assist you!

Did you find this information helpful?
Yes
No
Help us improve this page
Please provide feedback or comments
Comments (0)
Please  to leave a comment
Access denied
Access denied