using System;
using Autodesk.AutoCAD.ApplicationServices;
using Autodesk.AutoCAD.DatabaseServices;
using Autodesk.AutoCAD.EditorInput;
using Autodesk.AutoCAD.Runtime;
using Autodesk.AutoCAD.Geometry;
namespace 3dToPline
{
public class ToPline
{
[CommandMethod("ToPline")]
public void Tpolyline()
{
Document doc = Autodesk.AutoCAD.ApplicationServices.Application.DocumentManager.MdiActiveDocument;
Database db = doc.Database;
Editor ed = Autodesk.AutoCAD.ApplicationServices.Application.DocumentManager.MdiActiveDocument.Editor;
Entity entity = null;
double count2d;
double count3d;
count3d = 0;
count2d = 0;
// 创建三维多段线的选择集
TypedValue[] filList = new TypedValue[1];
// 二维三维选择集过滤 "*Polyline"