How to get all connections for every node

I have a diagram that has a number of bitmap nodes and connections (DirectedLineLinkTool) between a number of them. How can I cycle through all the bitmap nodes and tell (for each) what connections there are to another node? Ideally I would like to get the parent and child node it is connected to.


2 Replies

ST Steve April 22, 2008 03:34 PM UTC

For those who face a similar question, here is what I found that works...

For Each n As Node In Diagram1.Model.Nodes
Dim edge As IGraphEdge
For Each edge In n.Edges
Dim hn As Node
Dim en As Node
hn = edge.FromNode
en = edge.ToNode
If hn.Name = n.Name Then
Debug.WriteLine(hn.Name & " connected to " & en.Name)
End If
Next
Next



FS Fathima Shalini P Syncfusion Team April 25, 2008 08:28 AM UTC

Hi Steve,

Thank you for your update.

Regards,
Fathima


Loader.
Up arrow icon