c# Application.DoEvents

public static void Delay(int ms)
        {
            int start = System.Environment.TickCount;
            while (System.Environment.TickCount - start < ms)
            {

		//调用此方法将导致当前线程暂停,但处理所有等待窗口消息。
                Application.DoEvents();
            }

        }


 

 

 

 

 

 

 

        


 

 

 

posted on 2015-04-21 14:14  浮沉魅影  阅读(191)  评论(0编辑  收藏  举报

导航