Giorgio Devoti
Guest
Good day to all,
I have an autocad programming problem from an external application.
I can practically open autocad and a design, but I can't access other objects.
the code is as follows:
dim acadapp as new acadapplication
dim acaddoc as acaddocument
dim levels as acadlayers
set acadapp = createobject("autocad.application")
acadapp.visible = true
acadapp.documents.open filename, true
set acaddoc = acadapp.documents(1)
acaddoc.activate
'// at this point autocad is open and the design is loaded
set levels = acadapp.activedocument.layers
'// at this point the error is highlighted:
run-time error'-2145386390(8020006a)':
no matching database found
I press that:
the vb project has a reference to the library:
autocad 2008 type library
the project is compiled without errors
I already did a successful search based on the error code
Can someone help me?
I have an autocad programming problem from an external application.
I can practically open autocad and a design, but I can't access other objects.
the code is as follows:
dim acadapp as new acadapplication
dim acaddoc as acaddocument
dim levels as acadlayers
set acadapp = createobject("autocad.application")
acadapp.visible = true
acadapp.documents.open filename, true
set acaddoc = acadapp.documents(1)
acaddoc.activate
'// at this point autocad is open and the design is loaded
set levels = acadapp.activedocument.layers
'// at this point the error is highlighted:
run-time error'-2145386390(8020006a)':
no matching database found
I press that:
the vb project has a reference to the library:
autocad 2008 type library
the project is compiled without errors
I already did a successful search based on the error code
Can someone help me?