“mscorlib.dll中出现'System.IO.IOException'类型的第一次机会异常” [英] "A first chance exception of type 'System.IO.IOException' occurred in mscorlib.dll "

查看:574
本文介绍了“mscorlib.dll中出现'System.IO.IOException'类型的第一次机会异常”的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

那里!

我是WCF的新人。这些天,我正在学习。

我做了一个空的解决方案,这个解决方案包含4个项目:两个c#libs,两个控制台作为主机和客户端。程序运行良好,但是当客户端在主机之后启动时,它会在调试输出窗口中提出此信息:类型的第一次机会异常:mscorlib.dll中发生了System.IO.IOException

但是,该程序看起来很好并得到正确的答案,所以我想知道这个问题意味着什么。

谢谢!

Hi, there!
I am the new guy on WCF. These days, I''am learning that.
I made a empty solution, and this solution contains 4 projects: two c# libs, and two consoles as host and client. the programs ran well, but when client started after host, it raise this info in debug output window: "A first chance exception of type: System.IO.IOException occurred in mscorlib.dll"
But, the program looks well and get the right answer, so I want to know what this problem means.
Thanks!

推荐答案

实际上,我几乎可以肯定,虽然这是一个例外,但它不是问题。您可以捕获并处理它并忽略它,但您需要找到根本原因。检查你的输出,并尝试捕获你怀疑的块。在消息框中打印出异常,以便您可以更好地了解发生的事情。



我遇到这种类型的异常有时只是为了发现它是造成火灾的另一个结果。
Actually, I will almost bet that while this is the exception that was caught that it is not the problem. You could catch and handle this and ignore it, but you need to find the underlying cause. Check your output, and do a try catch on the block that you suspect. Print out the exception in a message box so that you can get a better feel for what is occuring.

I hit this type of exception sometimes only to find out that it is another result of action causing the fire.


这篇关于“mscorlib.dll中出现'System.IO.IOException'类型的第一次机会异常”的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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