简体   繁体   English

WPF应用程序崩溃而不会引发任何异常

[英]WPF Application Crashing Without throwing any Exceptions

Iam created a WPF Application in framework 4.5 and deployed as ClickOnce Application. Iam在框架4.5中创建了WPF应用程序,并将其部署为ClickOnce应用程序。 It is for Connecting and write the QuickBooks(3rd party) Software. 它用于连接和编写QuickBooks(3rd party)软件。 The Application is working fine On every system except few systems. 该应用程序在除少数系统之外的所有系统上都可以正常工作。 In few systems it is got crashed even if I am keeping the Application as idle.(After Connecting to the 3rd party software). 在少数系统中,即使我保持应用程序为空闲状态,该应用程序也会崩溃。(连接到第三方软件之后)。 I don't know what is exactly happens with only few systems. 我不知道只有少数几个系统会发生什么情况。

After crashing it is immediately Opens the JIT. 崩溃后立即打开JIT。 In that the following call stack i had 在我下面的调用堆栈中

4036a9ae()  Unknown
[Frames below may be incorrect and/or missing]  
kernel32.dll!@BaseThreadInitThunk@12()  Unknown
ntdll.dll!__RtlUserThreadStart()    Unknown
ntdll.dll!__RtlUserThreadStart@8()  Unknown

I have added all exception handling mechanisms includes catching Dispatcher Unhandled exception and Unhandled exceptions. 我添加了所有异常处理机制,包括捕获Dispatcher未处理的异常和未处理的异常。 even though it is not catch any of the exceptions. 即使它没有捕获任何异常。

Can anyone tell me, how to resolve this issue or How to find out the exact reason behind it? 谁能告诉我如何解决此问题或如何找出其背后的确切原因? The last two weeks I am trying to resolve it. 最近两个星期,我正在设法解决它。 在此处输入图片说明

My event Logs shows below 我的事件日志显示如下

Exception code: 0xc00001a5
Fault offset: 0x00056738
Faulting process id: 0xe9c

Goto project properties of your solution and set the application build start type to Console Application, then in the Constructor of MainWindow use try catch something like below 转到解决方案的项目属性,然后将应用程序的构建开始类型设置为“控制台应用程序”,然后在MainWindow的Constructor中使用try捕获如下内容

public MainWindow()
{
   try{
   InitializeComponent();
   //you remaining code
   }
   catch(Exception ex){
     Console.Out.Writeline(ex.Message);
   }
}

then deploy on the pcs where your app crashes...and see in the console whats the error 然后在您的应用崩溃的PC上进行部署...并在控制台中查看错误是什么

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM