AcadPoint是对象,不是数据类型,当然这样赋值(a(1)=0)是会出错的!! Sub Example_AddPoint()
' 该示例在模型空间中创建一个点。
Dim pointObj As AcadPoint
Dim location(0 To 2) As Double
' 定义点的位置
location(0) = 5#: location(1) = 5#: location(2) = 0#
' 创建点
Set pointObj = ThisDrawing.ModelSpace.AddPoint(location)
ZoomAll
End Sub |