Connecting VB.NET to 64 bit version of AutoCAD
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
I have a standalone VB.NET program that we use to mangage our AutoCAD Electrical databases and insert components (blocks) into AutoCAD. It has worked fine until we started deploying 64 bit computers. Now, it won't connect to AutoCad (again the 64 bit vesions don't work, 32 bit works fine).
Below are snippets from my VB.NET app. Do I need to connect differently for 64 bit machines? (I aplogize for not displaying the exception message when I try to connect to AutoCAD. The 64 bit computer that is having this problem is in a remote office and the engineer is not in today to let me log in.)
--------------------------
Imports System
Imports System.Runtime.InteropServices
Imports Autodesk.AutoCAD
Imports Autodesk.AutoCAD.Interop
Imports Autodesk.AutoCAD.Interop.Common
Imports System.Runtime.InteropServices.Marshal
Imports Autodesk.AutoCAD.Interop.AcadDocumentClass
Public acadapp As Autodesk.AutoCAD.Interop.AcadApplication
Public acadDoc As Autodesk.AutoCAD.Interop.AcadDocument
acadapp = System.Runtime.InteropServices.Marshal.GetActiveObject("AutoCAD.Application.18.2")