void PlcToConnect() { try { SySetHeip.ConfigurationInfo(SySetHeip.GetSysConfig().Tables[0]); //查询系统配置文件 SySetHeip.ConfigureMES(SySetHeip.GetSysConfigMES().Tables[0]); //查询MES系统配置文件 StocketInfo.StocketInfo s = new StocketInfo.StocketInfo(); s.socket = SocketHelper.tcpConn(SySetHeip.Plc_ip.Trim(), 9094, 10); SocketHelper.socketList.Add(s); } catch { } }
private void ChargeNumberRevise_Click(object sender, EventArgs e) { List <string> list = new List <string>(); for (int i = 0; i < 11; i++) { TextBoxX C = (TextBoxX)this.Controls.Find("ChargeNumber" + (i + 1), true)[0]; list.Add(C.Text.Trim()); } if (SySetHeip.UploadChargeNumberMES(list) > 0) { Common.Msg.Warning("修改成功"); SySetHeip.ConfigureMES(SySetHeip.GetSysConfigMES().Tables[0]);//查询MES系统配置文件 } else { Common.Msg.Warning("修改失败"); } }