怎样将List<PointF> pointsA转换为pointsA[]??
定义的list:
List<PointF> pointsA = new List<PointF>();
pointsA.Add(new PointF (1,1));
pointsA.Add(new PointF (1,1.5F));
pointsA.Add(new PointF (2,2));
pointsA.Add(new PointF (3,4));
pointsA.Add(new PointF (6,5.5F));
pointsA.Add(new PointF (9,9));
画折线的函数:g.DrawLines(pen,this.pointsA);要求pointsA为point[]类,
求转换方法!有其他解决方法也可!谢谢!!
------解决方案--------------------
g.DrawLines(pen, this.pointsA.Select(x => new Point(x.X, x.Y)).ToArray());