定时器的写法 winform

 

private void timer1_Tick(object sender, EventArgs e)
{

 

if ( tttttflag)
{
Action action = SyncCompanyJJ;
action.BeginInvoke(null, null);
}

}

 

tttttflag 方法体内 对该字段进行锁定  开始时候为false 完成时为for 

posted on 2017-08-18 17:16  雪原日暮  阅读(262)  评论(0编辑  收藏  举报