Prod.: Engine, ver.: 6, ID: 60000176, HowTo : How can I read the polylines attached to a polyhatch object?

HowTo : How can I read the polylines attached to a polyhatch object?

Article60000176
TypeHowTo
ProductEngine
Version6
Date Added6/1/2007
Submitted byPeter Chanios
Keywords

Subject

How can I read the polylines attached to a polyhatch object?

Summary

How can I read the polylines attached to a polyhatch object?

Solution

You can take the vdCurves from a hatch as following. Note that a hatch object may contain vdCircle,vdArc and generally all types of vdCurves.
 
Where hatch is the vdPolyhatch object.

foreach (VectorDraw.Professional.vdCollections.vdCurves var in hatch.PolyCurves)
{
    foreach (VectorDraw.Professional.vdFigures.vdCurve var1 in var)
    {
        VectorDraw.Professional.vdFigures.
vdPolyline poly1 = var1 as VectorDraw.Professional.vdFigures.vdPolyline;
         if (poly1 != null) MessageBox.Show("Found Polyline");
    }
}