.NET
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

My .NET modules just stop working!

6 REPLIES 6
Reply
Message 1 of 7
maciej.szczudlo
845 Views, 6 Replies

My .NET modules just stop working!

I have written plenty of .NET modules which were run in Auto Cad 2007 via NETLOAD.

This modules are used in my company on 15 computers.

But sometimes my colleagues inform me that .NET modules stop working.

There's no errors during NETLOAD command, but when I try to call module method
specified in [CommandMethod("XXX")] editor returns message:

Unknown Command "XXX". Press F1 for help.

Only solution I found is to reinstall AutoCad 2007 again.
I hope it is temporary.

Has anybody idea what can it be?

AutoCad 2007
Visual Studio 2008, C#
Windows XP, SP3
.NET Framework 3.5 SP1
6 REPLIES 6
Message 2 of 7

Make sure the people using your program know that if they restart AutoCAD, they must redo Netload
Message 3 of 7
Anonymous
in reply to: maciej.szczudlo

Hello maciej.szczudlo,
I've run into this with C# .NET addins and have not been able to figure out
what happened. I've never run into this with VB .NET addins (can't explain
it).

With the C# addins that quit working, I was able to convert to VB and they've
never quit working (go figure).

> I have written plenty of .NET modules which were run in Auto Cad 2007
> via NETLOAD.
>
> This modules are used in my company on 15 computers.
>
> But sometimes my colleagues inform me that .NET modules stop working.
>
> There's no errors during NETLOAD command, but when I try to call
> module method specified in [CommandMethod("XXX")] editor returns
> message:
>
> Unknown Command "XXX". Press F1 for help.
>
> Only solution I found is to reinstall AutoCad 2007 again. I hope it is
> temporary.
>
> Has anybody idea what can it be?
>
> AutoCad 2007
> Visual Studio 2008, C#
> Windows XP, SP3
> .NET Framework 3.5 SP1
Message 4 of 7

For All persons that face to this problem in their first step.

in the Visual studio in References for acdbmgd.dll and acmgd.dll, change their "Copy Local" properties to "False"

for more information Refer :

http://forums.autodesk.com/t5/NET/Unknown-Commands/m-p/2616003/highlight/true#M17273

Regards

Rise

Message 5 of 7
Jeffrey_H
in reply to: Anonymous

Hey Michael,

 

The only thing I have noticed different with VB and C# is if you create a project using the AutoCAD templates VB's application type is a WPF class library and C# output type is a Class library.

I do not know if that would have anything to do it as I have never seen an option to select a WPF class library.

And using 2007 I do not know if you would use the templates.

 

You can also find your answers @ TheSwamp
Message 6 of 7
wesbird
in reply to: Jeffrey_H

Does AutoCAD 2007 support WPF? I have a question here without any answer. 

Windows 10 64 bit, AutoCAD (ACA, Map) 2023
Message 7 of 7
HomeBoyLV
in reply to: maciej.szczudlo

I've had this happen before. The problem is usually an error in the init section. If you get one, AutoCAD just return to the command prompt without informing you there is an error (How RUDE :))

 

Add a try/Catch Block in your Init section. and trap it there. IIRC, AutoCAD is in an unknown state to your app, so you might not be able to get the editor, if not,  use standard logging functions to log the error

 

HomeBoy Out

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk DevCon in Munich May 28-29th


Autodesk Design & Make Report

”Boost