private void Form1_Load(object sender, EventArgs e) { //string sql = "select xuhao as id,L1name as name,scanrate,datatype from L1OPC_TAG where used=1 and type=" + 0 + " order by id "; ////DbMySql.GetDataTable(sql); ////var dt = new sqlDbHelp().Query(sql); //var dtb = DbMySql.GetDataTable(sql); //var count = dtb.Rows.Count; setupDbsg(); setupMqhs(); setCasterWeightInfo(); setCasterinfo(); DateTime dt = DateTime.Now; label22.Text = dt.ToString("yyyy-MM-dd HH:mm:ss"); //服务运行中 serviceList sl = new serviceList(); sl.Open(); KepServer.GetInstance(); //激活两个timer timer_mqhs.Enabled = true; timer_sll.Enabled = true; //2021-03-11 取消了大包剩钢的计算 // timer_dabaoshenggang.Enabled = true; }
private void Form1_Load(object sender, EventArgs e) { setupMqhs(); setCasterWeightInfo(); setCasterinfo(); setupDbsg(); DateTime dt = DateTime.Now; label22.Text = dt.ToString("yyyy-MM-dd HH:mm:ss"); //服务运行中 serviceList sl = new serviceList(); sl.Open(); //激活两个timer timer_mqhs.Enabled = true; timer_sll.Enabled = true; timer_dabaoshenggang.Enabled = true; }