停止对异常事件的捕获

This commit is contained in:
zhengxuan.zhang
2024-04-22 16:36:43 +08:00
parent de5438ad49
commit 7d4261806f
2 changed files with 8 additions and 5 deletions
+6 -3
View File
@@ -102,9 +102,12 @@ namespace HexcalMC.Hexcal
try
{
WatchStatus = false;
_mWatchSocket.Close();
_mWatchSocket.Dispose();
_mWatchSocket = null;
if (_mWatchSocket != null)
{
_mWatchSocket.Close();
_mWatchSocket.Dispose();
_mWatchSocket = null;
}
_dictThread.Clear();
_dictSocket.Clear();
+2 -2
View File
@@ -843,7 +843,7 @@ namespace HexcalMC
if (_mAcsConnected)
{
DisableFaultEvent(); //取消注册事件
//DisableFaultEvent(); //取消注册事件
_acs.CloseComm();
}
@@ -1078,7 +1078,7 @@ namespace HexcalMC
_mlblEnable[1] = lblEnable1;
_mlblEnable[2] = lblEnable2;
EnableFaultEvent(); //订阅错误事件
//EnableFaultEvent(); //订阅错误事件
}
public static bool IsWithinLimit(Point3D point) //判断点是否在行程范围内