Applies to: Nevron Diagram for .NET

How to iterate through the diagram nodes?

You can easily iterate through each individual node in the diagram. Since the diagram uses the consistent Nevron DOM (Document Object Model), it can be easily traversed. In fact the entire diagram is a tree of diagram elements. The following code obtains all elements in this tree which are 2D shapes:

[C#]
NNodeList shapes2D = NDrawingDocument1.Descendants(NFilters.Shape2D, -1);

[VB.NET]
Dim shapes2D As NNodeList = NDrawingDocument1.Descendants(NFilters.Shape2D, -1)

Article ID: 45, Created On: 10/5/2010, Modified: 11/15/2010