Hi, -SENL1362-!
Thank you for answer and code.
Unfortunately I did not understand anything in it))) I'm still at a very early stage of education.
I understand this code (from AutoCAD ActiveX and VBA Reference):
Sub Example_GetBoundingBox()
' Этот пример строит в пространстве модели линию и определяет размеры области объекта
Dim startPoint(0 To 2) As Double
Dim endPoint(0 To 2) As Double
Dim lineObj As AcadLine
' Создаем линию в пространстве модели (или определяем ее)
startPoint(0) = 2#: startPoint(1) = 2#: startPoint(2) = 0#
endPoint(0) = 4#: endPoint(1) = 4#: endPoint(2) = 0#
Set lineObj = ThisDrawing.ModelSpace.AddLine(startPoint, endPoint)
ZoomAll
Dim minExt As Variant
Dim maxExt As Variant
' Метод возвращает максимальную и минимальную точку области объекта
lineObj.GetBoundingBox minExt, maxExt
' Печатаем минимальные и максимальные размеры области
MsgBox "Текущие размеры объекта:" & vbCrLf _
& "Min Extent: " & minExt(0) & "," & minExt(1) & "," & minExt(2) _
& vbCrLf & "Max Extent: " & maxExt(0) & "," & maxExt(1) & "," & maxExt(2), vbInformation, "GetBoundingBox пример"
End Sub
Very easy: Create object in model space, get his bounding box and print in message box!
I do not understand the concept of AutoCAD NET API and this is sad 😞
Something like I've done with the help of "Using Autodesk.AutoCAD.Interop", but I have new problem: I can't show Form with report after it. 😞
Sad, sad and sad!
Where can I find a good explanation of the concept of AutoCAD NET API?
Thank you for your responsiveness!