构造 x 线可以放置在 3D 空间中的任何位置,并在两个方向上延伸到无穷大。 若要创建 xline,请使用以下方法。此方法通过两点方法指定线;输入或选择两个点来定义方向。第一个点,即根,被认为是构造线的中点。AddXLine 添加施工线下面的示例代码使用两点 (5, 0, 0) 和 (1, 1, 0) 创建一个对象。XLine Sub Ch3_AddXLine() Dim xlineObj As AcadXline Dim basePoint(0 To 2) As Double Dim directionVec(0 To 2) As Double ' Define the xline basePoint(0) = 2#: basePoint(1) = 2#: basePoint(2) = 0# directionVec(0) = 1#: directionVec(1) = 1#: directionVec(2) = 0# ' Create the xline in model space Set xlineObj = ThisDrawing.ModelSpace.AddXLine(basePoint, directionVec) ThisDrawing.Application.ZoomAll End Sub |
|Archiver|CAD开发者社区 ( 苏ICP备2022047690号-1 苏公网安备32011402011833)
GMT+8, 2025-1-8 19:41
Powered by Discuz! X3.4
Copyright © 2001-2021, Tencent Cloud.