Get a list of all 2D shapes from the drawing

Applies to: Nevron Diagram for .NET

How to get a list of all 2D shapes from the drawing?

To enumerate all 2D shapes from the document, you can use the following code:

[C#]
foreach (NShape shape in document.Descendants(NFilters.Shape2D))
{
  
}

[VB.NET]
For Each shape As NShape In document.Descendants(NFilters.Shape2D)
Next

To select a shape use this code:
View.Selection.SingleSelect(shape);

Article ID: 5, Created On: 9/24/2010, Modified: 11/15/2010