kingzgh 发表于 2009-2-11 20:37:00

[求助]画剖面线

我打算学习画剖面线
   直线我是会的,但是箭头不知道怎么处理以及转角处的转折线不知道怎么画及转角处的标签字母如何写出?最好画完后能够对箭头、转角线及标签字母可以编辑??
   有没有人能提供一个大概的思路如何完成或者提供一段示例代码,非常感谢!!!!!
file:///D:/我的文档/My%20Pictures/2.bmp

caiqs 发表于 2009-2-13 08:40:00

这是VBA帮助里的,我改了一下,你自已看吧
Sub Example_AddLeader()
    ' This example creates a leader in model space.
    ' The leader is not attached to any annotation object
    ' in this example.
   
    Dim leaderObj As AcadLeader
    Dim points(0 To 8) As Double
    Dim leaderType As Integer
    Dim annotationObject As AcadObject
    Dim insertpt(2) As Double
    insertpt(0) = 15: insertpt(1) = 20: insertpt(2) = 0
    Set annotationObject = ThisDrawing.ModelSpace.AddMText(insertpt, 30, "例子")
    annotationObject.Height = 6
   
    points(0) = 0: points(1) = 0: points(2) = 0
    points(3) = 10: points(4) = 10: points(5) = 0
    points(6) = 20: points(7) = 10: points(8) = 0
    leaderType = acLineWithArrow
    'Set annotationObject = Nothing
      
    ' Create the leader object in model space
    Set leaderObj = ThisDrawing.ModelSpace.AddLeader(points, annotationObject, leaderType)
    ZoomAll
   
End Sub

wuyunpeng888 发表于 2009-2-22 19:18:00

你想要的并不是剖面线,是剖切符号
带箭头的可以用多段线做
页: [1]
查看完整版本: [求助]画剖面线