sanderson Posted June 28, 2011 Posted June 28, 2011 Visual Studio 2008 / VB.NET AutoCAD 2006 Hi: This worked last week. Somehow it is no longer working now. I must be missing something. I need to open a drawing from VB.NET. Wheh I run this code, I get the following error: A first chance exception of type 'System.Runtime.InteropServices.COMException' occurred in MakeSpoolFix.exe Code: Dim fullname As String = "L:\3105\310556A1.dwg" Try acadApp = GetObject(, "AutoCAD.Application.16.2") Catch acadApp = CreateObject("AutoCAD.Application.16.2") End Try acadApp.Visible = True Debug.WriteLine(fullName) Me.lblStatus.Text = "Running MakeSpool Fix on " & fullName & "..." acadApp.Documents.Open(fullName, False) acadDoc = acadApp.ActiveDocument acadDoc.SendCommand("(wblockpurge) ") Thanks in advance fr the help! Quote
BIGAL Posted July 1, 2011 Posted July 1, 2011 I dont know the answer to your problem but I can see another developing "AutoCAD.Application.16.2" What happens when you upgrade your autocad and its now 16.3. Ok for testing but I would do a call to a routine that checks version numbers etc I have one sub that has version numbers in it and autoload it so available anytime. upgrade software upgrade 1 program only. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.