多段线提取点坐标-CAD-vba

整理文档很辛苦,赏杯茶钱您下走!

免费阅读已结束,点击下载阅读编辑剩下 ...

阅读已结束,您可以下载文档离线阅读编辑

资源描述

PrivateSubGetLWPOLYLINECoordinates()Dimss_dimAsAcadSelectionSet,entAsAcadLWPolylineDimdxf_code()AsInteger,dxf_value()AsVariantDimiAsLong,jAsLongDimdbCorAsVariant,xAsDouble,yAsDouble,zAsDoubleSetss_dim=ThisDrawing.SelectionSets.Add(ssLine1)ReDimdxf_code(0),dxf_value(0)dxf_code(0)=0:dxf_value(0)=LWPOLYLINEss_dim.SelectacSelectionSetAll,,,dxf_code,dxf_valueOpend:\¶à¶ÎÏßÌáÈ¡µã.txtForAppendAs#1ForEachentInss_dimForj=0ToUBound(ent.Coordinates)\2x=ent.Coordinates(j*2)y=ent.Coordinates(j*2+1)Print#1,X&x&,Y&yNextNextClose#1ss_dim.Clearss_dim.DeleteEndSub

1 / 1
下载文档,编辑使用

©2015-2020 m.777doc.com 三七文档.

备案号:鲁ICP备2024069028号-1 客服联系 QQ:2149211541

×
保存成功