I'm having trouble with my command not loading via a netload in AutoCAD 2012 SP1 64bit running on Windows 7 64bit. It works on most of my user's computers, but on a couple of the computers it doesn't seem to be doing anything. I'm using Visual Studio 2010 for coding and debugging, but I don't have debugging software on the computer that is causing the problem. I've attached my commands class in it's entirety to this post in the hopes that someone can point me in the right direction. The dll resides local on the user's computer and is not in a network location. When I run the netload on the development machine or one of my other working users, I get the message boxes and the program seems to run fine, but on the computers that aren't working I get nothing. No errors, no message boxes, nothing. Any questions or solutions would be greatly appreciated as I've been trying all sorts of things to see what I can do to resolve the problem. Thanks in advance.
At least when starting command _NETLOAD and pointing to your dll you get some infos at command-line,
- alfred -
>> Actually there is no error in the command line.
I can't beleive that (even tried <F2> to see more lines?), but ok.
Have you tried any of the sample-projects shipped with the ObjectARX-kit? Do they also not load/run?
- alfred -
an additional idea: remove the INITIALIZE part, if there are exceptions in it the loading of the DLL may fail.
You can try to run your initialize at the first command-start of one of your commands (at least for a test period)
- alfred -
Hope this makes sense. Here is my entire command prompt from when I try the netload:
Customization file loaded successfully. Customization Group: ACAD
Customization file loaded successfully. Customization Group: AUTOCADWS
Customization file loaded successfully. Customization Group: AUTODESKSEEK
Customization file loaded successfully. Customization Group: CONTENTEXPLORER
Customization file loaded successfully. Customization Group: EXPRESS
Unknown command "PID". Press F1 for help.
"unknown command" does not necessarily mean "DLL not loaded". This also happens when you used the wrong framework for creating your DLL or any defects in the framework-installations.
Try my two tips above, remove the INITIALIZE sequence in your project for test and try to load another DLL from any other project.
HTH, - alfred -
Alright, I tried loading a different dll and this one worked correctly. I also removed the initialize code completely and removed the IExtensionApplication inheritance my commands class. The problem still exists on my one computer, but loads correctly on my other computer.
>> I tried loading a different dll [...] I also removed the initialize code
Wow, you are fast!
>> The problem still exists on my one computer, but loads correctly on my other computer.
What are the differences between those workstations (os, os servicepack, AutoCAD + SP, installed Frameworks, ...)
If on the "defect system" other DLLs work well I would start to do two things:
Good luck, - alfred -
Open the Registry editor, and go to the registry key where your application is creating the demand-load entries, and delete the entire key so that there is no demand-loading of your app to confuse things.
My guess is that AutoCAD is loading another copy of your assembly at startup, or when your command is issued.
If you're developing and use demand-loading you need to be sure that the location of the assembly in the registry is the same as the location of the assembly you're building and testing.