I'm programming on VBA for Autocad but until this day I can't found how to create or insert line on VB.NET.
I see that VB.NET have two kinds of concepts to use the acad files.
Using:
AcApplication.DocumentManager.MdiActiveDocument
;Using some like this, as transaction for more than one file all files of folders are declared as database and the block table and modifications as transactions, maybe I'm a little lost on the concepts but I'm new in VB.NET
I'm need a sample of how to create line or circle on VB.NET and insert on DXF drawing using the concept 2 as database because I need to modify a lot of drawings.
For Each Filedxf As IO.FileInfo In Modfiles
Try
Change = False
Dim MyDB As New Database(False, True)
MyDB.DxfIn(Filedxf.FullName.ToString, IO.Path.Combine(PathToChange, "dxf.log"))
Using MyTrans As Transaction = MyDB.TransactionManager.StartTransaction
Dim MyBT As BlockTable = MyDB.BlockTableId.GetObject(OpenMode.ForRead)
For Each MyBTRId As ObjectId In MyBT
Dim MyBTR As BlockTableRecord = MyBTRId.GetObject(OpenMode.ForRead)
For Each cadID As ObjectId In MyBTR
Select Case cadID.ObjectClass.DxfName.ToUpper
Case "TEXT"
Dim MyText As DBText = cadID.GetObject(OpenMode.ForWrite)
Select Case MyText.Layer.ToUpper
Thanks a lot for your help