1

I am having problems when I distribute software I developed, the compiled .exe runs fine on my system but when parsed to others it displays the below error, on both 32 bit and 64 bit systems.

I have tried many compile options, including obfuscating, building for any CPU, building for 64bit and 32, I also tried, building on other systems, all .dlls are supplied in the package, i even tired merging the .dlls that I could without breaking license agreements etc.

Even registered all .dlls on the other system.

Any ideas? I did some googling, but as a last resort i have had to ask here, Knowing my luck it will be something obvious, The error leads me to believe the dlls are not there but they are...

Here is the error below:

Problem signature:

Problem Event Name: CLR20r3 
Problem Signature 01: testtool.exe
Problem Signature 02: 1.0.0.0 
Problem Signature 03: 4e1ec8bf Problem
Signature 04: ScintillaNet 
Problem Signature 05: 2.2.3581.19319
Problem Signature 06: 4adf566e 
Problem Signature 07: 66e Problem
Signature 08: 5c 
Problem Signature 09: System.IO.FileNotFoundException
OS Version: 6.1.7600.2.0.0.272.7
Locale ID: 1033 
Additional Information 1: 0a9e
Additional Information 2: 0a9e372d3b4ad19135b953a78882e789 
Additional Information 3: 0a9e
Additional Information 4: 0a9e372d3b4ad19135b953a78882e789

...Runs fine on the system I compile it on.

The above leads me to think the dll's are not there... but they are.

Thanks kindly, Scott

jornh
  • 1,369
  • 13
  • 27
scott
  • 1,531
  • 2
  • 16
  • 29
  • It looks like a FileNotFoundException can you see what file? Are you running on Release build settings? – CodingBarfield Jul 20 '11 at 07:50
  • I will run it in dubug mode on other computers, i was using release builds, thanks for pointing that out, i should of thought, i will let you know how it goes., – scott Jul 20 '11 at 08:07
  • I think ScintillaNet assembly cant find file, maybe you forgot to copy something. If not try debug application [here](http://blogs.msdn.com/b/msdnts/archive/2006/11/24/how-to-debug-application-crash-hang-in-production-environment.aspx) is article how to debug application in production environment. – Renatas M. Jul 20 '11 at 08:09
  • i think the problem is i was running it in debug mode but the app is encrypted so it cant find the "mapping" file or the debug info as such... i think... there would be a better way to explain it if thats the error... nur it can find scintillanet all dlls are there its just bad error reporting i spose, it seems the problem is defeintly becuase i was running a debug version (encrypted) with no mapping file, ill try now with a release version to test this theory, ill let you know how i get on. – scott Jul 20 '11 at 08:44
  • hmm same problem, dosnt matter debug or release, now nothing shows up, no error the application just wont open on other computers, obviously the right .net version is on the other computers im testing it on. Ill see if Windbg can help – scott Jul 20 '11 at 09:35
  • Are you saying that you copy all Debug folder content to another machine and it displays the error? Have you checked any external dependencies that may be present in your application? Maybe a dll that is registered in GAC is absent on another machine – username Jul 20 '11 at 10:00

1 Answers1

6

If you have a .NET app that crashes for no apparent reason on another system, and the error report hints at the fact that an exception is thrown (like System.IO.FileNotFoundException), you should add a handler for unhandled exceptions (AppDomain.CurrentDomain.UnhandledException) and then just output the whole exception (e.ExceptionObject.ToString()) with a message box. The stack trace should give some more insight into what is happening (you can also make use of the other Exception properties). A debug build with PDB files will additionally provide line numbers.

See http://www.csharp-examples.net/catching-unhandled-exceptions/

It's important to add this event handler at startup of your app, before the exception has a chance to happen. Using tools like Windbg is usually overkill for managed exceptions.

floele
  • 3,668
  • 4
  • 35
  • 51