如何修复“System.AggregateException”发生在mscorlib.dll“ [英] how to fix "'System.AggregateException' occurred in mscorlib.dll"

查看:2690
本文介绍了如何修复“System.AggregateException”发生在mscorlib.dll“的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在调试器和程序停止执行时收到这样的问题。调试器不显示我的行,所以我不知道该修复什么。

I receive such problem in debugger and program stops executing. Debugger doesn't show me the line so I don't know what to fix.


类型为'System.AggregateException'的未处理的异常发生在
mscorlib.dll

An unhandled exception of type 'System.AggregateException' occurred in mscorlib.dll

附加信息:没有观察到任务的异常
通过等待任务或访问其异常属性。作为
结果,定位器线程重新引发了未查看的异常。

Additional information: A Task's exception(s) were not observed either by Waiting on the Task or accessing its Exception property. As a result, the unobserved exception was rethrown by the finalizer thread.

无法获取本地或参数的值,因为它不是
可能在这个指令指针,可能是因为它已被
优化掉。 System.Threading.Tasks.TaskExceptionHolder

Cannot obtain value of local or argument '' as it is not available at this instruction pointer, possibly because it has been optimized away. System.Threading.Tasks.TaskExceptionHolder

如何解决我的问题?

我也发现这个非常相似的问题无法获取本地或参数的值,因为该指令指针不可用,可能是因为已被优化

I also found this question which is pretty similar Cannot obtain value of local or argument as it is not available at this instruction pointer, possibly because it has been optimized away

推荐答案

正如消息所说,你有一个任务抛出一个未处理的异常。

As the message says, you have a task which threw an unhandled exception.

打开所有例外的破解(调试,例外)并重新运行该程序。

这将首先显示原始异常。

Turn on Break on All Exceptions (Debug, Exceptions) and rerun the program.
This will show you the original exception when it was thrown in the first place.

这篇关于如何修复“System.AggregateException”发生在mscorlib.dll“的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆