Thread thread = new Thread(new ThreadStart(delegate() { oledbConn.Open(); foreach (DataRow x in yxdms) { toCut(x["yxdm"].ToString().Trim()); } oledbConn.Close(); })); thread.Start(); //刷新状态显示 System.Windows.Forms.Timer timer = new System.Windows.Forms.Timer(); timer.Interval = 1000; timer.Tick += (delegate(object sender2, EventArgs e2) { label2.Text = currYxdm; }); timer.Start();