1:实体填充 完整代码如下: On Error Resume Next ' 连接至 AutoCAD 应用程序 Dim acadApp As AcadApplication Dim docObj As AcadDocument Set acadApp = GetObject(, "AutoCAD.Application.17.1") Set docObj = acadApp.Application.Doc ...
1:绘制构造线 代码如下: On Error Resume Next ' 连接至 AutoCAD 应用程序 Dim acadApp As AcadApplication Dim docObj As AcadDocument Set acadApp = GetObject(, "AutoCAD.Application.17.1") Set docObj = acadApp.Application.Docum ...
本次我们通过VB来设置文档窗口,文档窗口就是我们绘制图形的黑色区域。 1:设置文档大小 代码如下: On Error Resume Next ' 连接至 AutoCAD 应用程序 Dim acadApp As AcadApplication Dim docObj As AcadDocument Set acadApp = GetObject ...
1:更改AutoCAD窗口位置与大小 代码如下 : On Error Resume Next ' 连接至 AutoCAD 应用程序 Dim acadApp As AcadApplication Dim docObj As AcadDocument Set acadApp = GetObject(, "AutoCAD.Application.17.1") Set docObj = acadApp.A ...
环境与引用步骤同:AutoCAD二次开发教程(1)-通过VB6绘制直线 1:绘制点 代码如下: On Error Resume Next ' 连接至 AutoCAD 应用程序 Dim acadApp As AcadApplication Dim docObj As AcadDocument Set acadApp = GetObject(, "AutoCAD.Ap ...