I get "Problem in Loading Application" with AutoCAD 3D Map 2011 on
AcadMap = acad.GetInterfaceObject("AutoCADMap.Application")
What should i do to fix this?
I have no problem with this code with AutoCAD Map 2011 in one computer and AutoCAD Map 2012 in another computer, both are Win7 64-bit:
Public Sub MapTest() Dim app As AutocadMAP.AcadMap Dim proj As AutocadMAP.Project Set app = Application.GetInterfaceObject("AutoCADMap.Application") Set proj = app.Projects(ThisDrawing) MsgBox "Projection: " & proj.CurrentProjection End Sub
Are you sure you have set reference to AcMapVbaApi.tlb?
Norman Yuan
i'm designing a 64 bit VB.NET for win7 code on a 32 bit machine XP machine.
I did not have the reference to AcMapVbAbi.tlb, should i use this one or AcMapVbAbi.dll?
and mostly i want to get the alliases after
acad.GetInterfaceObject("AutocCADMap.Application")
So, you are not doing VBA, then.
I do understand what does this mean:
<quote>
i'm designing a 64 bit VB.NET for win7 code on a 32 bit machine XP machine.
</quote>
What type of application you are doing, for which version of AutoCAD? If you are doing AutoCAD .NET API adding, there is not need to use Map's COM API (for pre AutoCAD 2014 version, you cannot use 32-bit COM API in your .NET addin.
IMO, if you use .NET for programming, you do not need Map's COM API at all.
Norman Yuan