在winforms中未处理套接字异常 [英] Socket Exception was unhandled in winforms

查看:68
本文介绍了在winforms中未处理套接字异常的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

每当我尝试在A win 7上运行基于IP地址的项目时,赢8或赢8.1系统意味着在那个时候我得到一个错误,称为SOCKET EXCEPTION WAS UNHANDLED如何克服这个? plss帮我解决这个问题。



注意:如果我尝试在xp机器上运行此错误,那么这个错误就不存在了

Whenever i try to run an ip address based project on A win 7,win 8 or win 8.1 systems means on that time i got an error called SOCKET EXCEPTION WAS UNHANDLED how to overcome this?? plss help me to solve this.

Note: This error was not there if i try to run this on xp machine

推荐答案

'处理异常是必须的(和蹩脚的)答案。

你必须理解抛出异常的原因(异常对象本身产生的)很多有用的信息)然后在你的应用程序中正确处理它。

如果你没有遇到 Windows XP上的问题那么可能是execption之所以发生,是因为您的应用程序遇到了 UAC [ ^ ],但这只是一个疯狂的猜测。
'handle the exception' is the obligatory (and lame) answer.
You have to understand why the exception was thrown (the exception object itself produces a lot of useful info) and then properly handle it in your application.
If you are not experiencing the problem on Windows XP then possibly the execption occurs because your application hit the UAC[^], but that's just a wild guess.


这篇关于在winforms中未处理套接字异常的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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