Dim cad as CObject创建一个CObject实现
cad.CreateObject("autocad.application")'创建CAD对象
cad.Put "visible" ,1 ,vbTrue'设置CAD程序可见
dim ModelSpace As CObject = cad.get("ActiveDocument").Get("ModelSpace")'获得活动文档的ModelSpace空间
dim a(2) as Double = {1,2,0}'创建点a
dim b(2) as Double ={1000,1000,0}
ModelSpace.Run("AddLine",cobject(a()),cobject(b()))'画线