|
发表于 2003-6-6 19:06:00
|
显示全部楼层
Sub Example_PolarPoint()
' 这个示例演示了求出与基点距离某一长度并形成某一角度的点。
Dim polarPnt As Variant
Dim basePnt(0 To 2) As Double
Dim angle As Double
Dim distance As Double
basePnt(0) = 2#: basePnt(1) = 2#: basePnt(2) = 0#
angle = 0.1744444 ' 45 degrees
distance = 5
polarPnt = ThisDrawing.Utility.PolarPoint(basePnt, angle, distance)
' 从基点到Polar点创建一条直线。
Dim lineObj As AcadLine
Set lineObj = ThisDrawing.ModelSpace.AddLine(basePnt, polarPnt)
ZoomAll
End Sub |
|