Stack,
To start, this website is fantastic, you've helped me through a lot of issues in the past; thanks.
Moving forward, this program has been in existence, and in use, since AutoCAD 2000. The current version of the software is compatible up to ACAD 2017.
I work with a small team, and out of nowhere, my PC is struggling with the VB6/AutoCAD combination; the other developers are still working with no issues...
Late binding is used to get, or create, the object; depending on whether Acad is already running... e.g.
Set oAutoCad = GetObject(, "Autocad.Application")
If err.Number Then
err.Clear
Set oAutoCad = CreateObject("Autocad.Application")
If err.Number Then
MsgBox UCase$("Unable to launch AutoCAD Session")
End
Else
oAutoCad.Visible = True
End If
End If
There are two different executables (using the same binding technique) that work with ACAD to do different things. For both of them, the software fails on both CreateObject and GetObject with "Run Time Error 429 - ActiveX Component Cannot Create Object. However, adding '.20' to the call allows me to create an object, but I still can't bind to an existing. e.g...
Call CreateObject("Autocad.Application.20")
I believe the difference between myself and the team is that I recently had to re-install VB6 after some 'Error Accessing Registry' issues surfaced (immediately after a Windows update...weird). That's the big difference; everyone else has migrated from 7 to 10 with VB6 installed. I'm the first one to install on a windows 10 machine directly.
We were originally using SP6 with VB6, though this issue has brought some things to my attention. Apparently, they are still updating the service pack. So, the computer has recently been updated to SP6D. I've also tried installing the Cumulative Service Pack.
I've attempted to change the compatibility settings from Win 7, Win 8, XP's (all of them)... I have no idea.
I've run as administrator
It's a 64 bit machine.
The original VB6 MSDN library has been installed... for some reason, the SP6 wouldn't install correctly until it was... for that matter, that actual VB6 installation gets hung up on the end. It doesn't appear to affect much, but it must be doing something in the background (or not doing)
Any help would be greatly appreciated... here's to hoping.
******* New Information ******* Apparently, adding the '.20' is only good enough for one of the exes, the other requires and additional version number (e.g. "Autocad.Application.20.1")
To make it more interesting, if I start the project with the '20.1', stop the code the moment the object is created, wait for autocad to launch, set it to visible, open the drawing I need to connect to using the ACAD UI, then allow the program to continue, GetObject doesn't fail...
????