- 积分
- 765
- 明经币
- 个
- 注册时间
- 2006-12-2
- 在线时间
- 小时
- 威望
-
- 金钱
- 个
- 贡献
-
- 激情
-
|
楼主 |
发表于 2013-1-12 11:35:00
|
显示全部楼层
point1 = ThisDrawing.Utility.GetPoint(, vbCr & "请指定标注点")
point11 = ThisDrawing.Utility.TranslateCoordinates(point1, acWorld, acUCS, False)
point2 = ThisDrawing.Utility.GetPoint(point11, vbCr & "请指定标注位置")
point22 = ThisDrawing.Utility.TranslateCoordinates(point2, acWorld, acUCS, False)
If bz1.clzb.Value = False Then
vtext1 = "X=" & FormatNumber(point11(0), xiaoshu, vbTrue, vbFalse, vbFalse)
vtext2 = "Y=" & FormatNumber(point11(1), xiaoshu, vbTrue, vbFalse, vbFalse)
Else
vtext1 = "X=" & FormatNumber(point11(1), xiaoshu, vbTrue, vbFalse, vbFalse)
vtext2 = "Y=" & FormatNumber(point11(0), xiaoshu, vbTrue, vbFalse, vbFalse)
End If
mlp(0) = point1(0)
mlp(1) = point1(1)
mlp(2) = point1(2)
mlp(3) = point2(0)
mlp(4) = point2(1)
mlp(5) = point2(2)
Set ml = ThisDrawing.ModelSpace.AddMLeader(mlp, d)
ml.TextLineSpacingFactor = 0.85
ml.TextString = vtext1 & "\P" & vtext2
ml.ArrowheadType = acArrowNone
ml.TextRightAttachmentType = acAttachmentBottomOfTopLine '文字连接位置-右
ml.TextLeftAttachmentType = acAttachmentBottomOfTopLine '文字连接位置-左
ml.DogLegged = True
ml.LandingGap = 0
ml.TextHeight = height
ml.ArrowheadSize = 0
ml.DoglegLength = height |
|