VBA
Discuss AutoCAD ActiveX and VBA (Visual Basic for Applications) questions here.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

compile error in sub

2 REPLIES 2
SOLVED
Reply
Message 1 of 3
Mikexlt
394 Views, 2 Replies

compile error in sub

This code worls in c3d 2009 but fails in c3d 2014

 

 

Dim oAcadApp As AcadApplication
Set oAcadApp = ThisDrawing.Application


Const sCivilAppName = "AeccXUiLand.AeccApplication.6.0"
Dim oCivilApp As AeccApplication
Set oCivilApp = oAcadApp.GetInterfaceObject(sCivilAppName)
Dim oDocument As AeccDocument
Set oDocument = oCivilApp.ActiveDocument

 

Compile error 

 

Can't find project or library

 

Any Suggestions?

 

Thanks 

 

Mike

2 REPLIES 2
Message 2 of 3
remy.baud
in reply to: Mikexlt

Hi Mike,

 

Maybe it is the major/minor version  that you use in the GetInterfaceObject() call.

 

"AeccXUiLand.AeccApplication.6.0"

 

It's maybe no longer the "6.0" version but another one like (11.0???, 10.3???) and it's maybe why you can't load it.

 

See this post that is talking about it here.

 

http://knowledge.autodesk.com/support/autocad-civil-3d/troubleshooting/caas/discussion/t5/AutoCAD-Ci...

 

Regards,

Rémy

Message 3 of 3
Mikexlt
in reply to: remy.baud

Thanks Remy

 

Changed version to 10.3 and other errors to Object and works fine now

 

Mike

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report

”Boost