0

I am having a problem with my program which I develop in Visual Studio 2015.

It is a media player and up until now I had no such problem.

When I debug the program using VS's debugger, everything's fine and there's no error or crash.

However, when I deploy the program and install it on various computers, there's a specific error popping up each time I try to open a specific form.

See the end of this message for details on invoking just-in-time (JIT) debugging instead of this dialog box.

Then there is some assembly info and then:

************** JIT Debugging ************** To enable just-in-time (JIT) debugging, the .config file for this application or computer (machine.config) must have the jitDebugging value set in the system.windows.forms section. The application must also be compiled with debugging enabled.

For example:

<configuration>
    <system.windows.forms jitDebugging="true" />
</configuration>

When JIT debugging is enabled, any unhandled exception will be sent to the JIT debugger registered on the computer rather than be handled by this dialog box.

Let me note here that I did not experience such problem before with Visual Studio 2013,2012 and 2010.

Also, let me note that I've both tried deploying the program with JIT enabled and disabled, with the result being the same.

Patikol
  • 7
  • 8
  • Making your program work properly on other machines, and having it give good info when it crashes, is the other 90% of the project. You have to write an event handler for the AppDomain.CurrentDomain.UnhandledException event so you can tell the user (and above all yourself) what went wrong. – Hans Passant Feb 19 '17 at 15:20
  • Have you tried deploying your application with the build configuration set to `Release`? – Visual Vincent Feb 19 '17 at 15:21
  • @VisualVincent yes I've tried both Debug and Release configs but the result is the same. – Patikol Feb 19 '17 at 16:33
  • @HansPassant the thing is that this error shows up on every computer, even my own that I made this program, when ran outside VS. There wasn't any problem like that in the previous versions, and this problem appeared after I installed VS 2015 – Patikol Feb 19 '17 at 16:34
  • That means absolutely nothing as long as you don't know *why* it crashed. I explained what you need to do, make it happen, update your question with what you discovered. – Hans Passant Feb 19 '17 at 16:36
  • If you enable the JIT debugger (just in time debugger), your user needs to have a debugger installed. But who will have Visual Studio installed? See [this question](http://stackoverflow.com/questions/24874027/how-do-i-take-a-good-crash-dump-for-net) on how to capture a crash dump. In your case, WER LocalDumps should be a good idea. Ask one of your users to do it. Then load the crash dump in VS. – Thomas Weller Feb 19 '17 at 19:35
  • @Patikol, if all machines have the same issue, we would think about the setup package of this project or VS IDE, the JIT debugging captured the app Exception outside the VS., so you would think about the deployed app itself. Of course, please debug your app after you enable the Exception settings under Debug->Windows, we have to make sure that no exception. Not know how you deploy your app, but please also test it using different app, make sure that it is not the steps issue or others. If all VS2015 projects have this issue, please install the update 3 or repair your VS, re-create a new one. – Jack Zhai Feb 20 '17 at 06:15
  • @Patikol, what about this issue? Please feel free to share the latest information about this issue? If it was not resolved, as you said that you didn't have this issue in old VS version, do you deploy the same app using different VS version? – Jack Zhai Feb 22 '17 at 05:40
  • Hello and sorry for keeping unposted for so long. So what I did was try to find the real error that caused that window since I couldn't just remove it. It was a pain since I couldn't trust the debugger, and I needed to deploy and install my program for each test. After lots of tests I found the error in the code and I fixed it. Thanks for your time everyone. – Patikol Mar 05 '17 at 13:04

0 Answers0