用Event的事件通知,但时间不是整数50/3要做一次,要求时间精确!
这种时间应怎样控制?

解决方案 »

  1.   

    GetTickCountThe GetTickCount function retrieves the number of milliseconds that have elapsed since the system was started. It is limited to the resolution of the system timer. 
      

  2.   

    主要是向SetTimer那样,每隔50/3秒就调用一次函数!
      

  3.   

    查一查CSDN上的老帖子,关于精确计时、精确定时的。
      

  4.   


    x=GetCurrentTime();
    while(1)
    {
    if (GetCurrtentTime()-(50/3)*1000==x)
      {
        x=GetCurrentTime();
        ...
        continue;
       }
    }