CADVertex ouput problem
Moderators: SDS, support, admin
-
- Posts: 13
- Joined: 19 Jun 2019, 07:30
CADVertex ouput problem
Hello
I got polylines from block
and polyines's vertexes.
I made a list for each values of point x and point y from vertexs.
I would like to write these values in console.
It is a code that I wrote. I'm having a difficult to approach CADVertex Class.
if (block.Entities.EntType == EntityType.LWPolyline)
{
CADLWPolyLine PolylinesData = (CADLWPolyLine)block.Entities;
List<CADVertex> vertexes = new List<CADVertex>();
PolylinesData.Vertexes.ForEach(ent => vertexes.Add(ent as CADVertex));
vertexes.ForEach(Console.WriteLine);
}
Thanks!
I got polylines from block
and polyines's vertexes.
I made a list for each values of point x and point y from vertexs.
I would like to write these values in console.
It is a code that I wrote. I'm having a difficult to approach CADVertex Class.
if (block.Entities.EntType == EntityType.LWPolyline)
{
CADLWPolyLine PolylinesData = (CADLWPolyLine)block.Entities;
List<CADVertex> vertexes = new List<CADVertex>();
PolylinesData.Vertexes.ForEach(ent => vertexes.Add(ent as CADVertex));
vertexes.ForEach(Console.WriteLine);
}
Thanks!
Re: CADVertex ouput problem
Hello,
To write the Point.X and Point.Y values from a CADVertex object in the console, use the following code:
Mikhail
To write the Point.X and Point.Y values from a CADVertex object in the console, use the following code:
Code: Select all
vertexes.ForEach(vertex => Console.WriteLine("x={0}; y={1}", vertex.Point.X, vertex.Point.Y));
Technical Support E-mail: support@cadsofttools.com
Chat support on Skype: cadsofttools.support
Chat support on Skype: cadsofttools.support