|
我现在有一段程序在类模块中:
Function AutoCADConnect() '连接AutoCAD
On Error Resume Next
Set obj_Acad = GetObject(, "autocad.application")
If Err Then
Err.Clear
On Error Resume Next
Set obj_Acad = CreateObject("autocad.application")
If Err Then
Err.Clear
MsgBox "不能运行AutoCAD,请检查是否安装!", vbOKCancel, "警告!"
Exit Function
End If
End If
obj_Acad.Visible = True
Set obj_Doc = obj_Acad.ActiveDocument
Set obj_ModelSpace = obj_Doc.ModelSpace
'MsgBox "运行结束!", vbOKOnly, "工程1!"
boo = True
End Function
请教各位大侠的问题是如何将将以下的类模块中数据
obj_Acad
Set obj_Doc
Set obj_ModelSpace
在VB的form窗体,如何实现
debug.print obj_Acad --------> True
debug.print Set obj_Doc --------> True
debug.print Set obj_ModelSpace --------> True
|
|