连线逻辑修改
This commit is contained in:
commit
3b6ab69a71
5 files changed
+98
-131
No files matched your search
@@ -161,7 +161,7 @@ namespace SunlightCentralizedControlManagement_SCCM_.ViewModel
|
||||
|
||||
DispatcherTimer dis50ms = new DispatcherTimer
|
||||
{
|
||||
Interval = TimeSpan.FromMilliseconds(50) //毫秒
|
||||
Interval = TimeSpan.FromMilliseconds(10) //毫秒
|
||||
};
|
||||
dis50ms.Tick += new EventHandler(DisTimer_50MS);//每一秒执行的方法
|
||||
dis50ms.Start();//计时开始
|
||||
@@ -346,9 +346,9 @@ namespace SunlightCentralizedControlManagement_SCCM_.ViewModel
|
||||
return index;
|
||||
}
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
// LogGing.LogGingDATA("SDTD:" + ex.ToString());
|
||||
catch (Exception ex)
|
||||
{
|
||||
LogGing.LogGingDATA("SDTD:" + ex.ToString());
|
||||
return "ERR";
|
||||
}
|
||||
}
|
||||
@@ -363,44 +363,15 @@ namespace SunlightCentralizedControlManagement_SCCM_.ViewModel
|
||||
drEmployee[name] = Value;
|
||||
drEmployee.EndEdit();
|
||||
drEmployee.AcceptChanges();
|
||||
drEmployee.ClearErrors();
|
||||
// drEmployee.ClearErrors();
|
||||
}
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
// LogGing.LogGingDATA("SDTD:" + ex.ToString());
|
||||
}
|
||||
}
|
||||
public static void UpdataMachines(string key, DataRow Value)//更新数据
|
||||
{
|
||||
try
|
||||
{
|
||||
lock (Machines)
|
||||
{
|
||||
DataRow drEmployee = Machines.Select("IP='" + key + "'").First();
|
||||
drEmployee.BeginEdit();
|
||||
|
||||
if (Value["State"] != null) drEmployee["State"] = Value["State"];
|
||||
if (Value["WorkOrder"] != null) drEmployee["WorkOrder"] = Value["WorkOrder"];
|
||||
if (Value["Dyelot"] != null) drEmployee["Dyelot"] = Value["Dyelot"];
|
||||
if (Value["Temperature"] != null) drEmployee["Temperature"] = Value["WorkOrder"];
|
||||
if (Value["WaterLevel"] != null) drEmployee["WaterLevel"] = Value["WaterLevel"];
|
||||
if (Value["Process"] != null) drEmployee["Process"] = Value["Process"];
|
||||
if (Value["Step"] != null) drEmployee["Step"] = Value["Step"];
|
||||
if (Value["Message"] != null) drEmployee["Message"] = Value["Message"];
|
||||
if (Value["SYSKEY"] != null) drEmployee["SYSKEY"] = Value["SYSKEY"];
|
||||
if (Value["Groups"] != null) drEmployee["Groups"] = Value["Groups"];
|
||||
|
||||
drEmployee.EndEdit();
|
||||
drEmployee.AcceptChanges();
|
||||
drEmployee.ClearErrors();
|
||||
}
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
// LogGing.LogGingDATA("SDTD:" + ex.ToString());
|
||||
catch (Exception ex)
|
||||
{
|
||||
LogGing.LogGingDATA("SDTD:" + ex.ToString());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public static DataTable dt_d = new DataTable("DIO");
|
||||
public static DataTable dt_a = new DataTable("AIO");
|
||||
|
||||
Reference in new issue
Block a user