'生成点,实际上是创建块 Public Sub addpoint(ByVal p0 As Double, ByVal p1 As Double) Dim blockObj As AcadBlock Dim insertpoint(0 To 2) As Double insertpoint(0) = p0 insertpoint(1) = p1 insertpoint(2) = 0 Set blockObj = acadapp.ActiveDocument.Blocks.Add(insertpoint, "d1")
Dim blockobjref As AcadBlockReference Set blockobjref = acadapp.ActiveDocument.ModelSpace.InsertBlock(insertpoint, "d1", 1#, 1#, 1#, 0)
|