标签:enter ESS als art messages bsp max str form
1、挂起,不占CPU
sleep
2、不挂起,占cpu
procedure Delay(msecs:integer);
var
FirstTickCount:longint;
begin
FirstTickCount:=GetTickCount;
repeat
Application.ProcessMessages;
until ((GetTickCount-FirstTickCount) >= Longint(msecs));
end;
3、定时器
procedure timerfun(handle:Thandle;msg:word;identer:word;dwtime:longword);stdcall;
begin
showmessage(‘到点了‘);
killtimer(handle,identer);//关闭定时器
end;
标签:enter ESS als art messages bsp max str form
原文地址:https://www.cnblogs.com/jijm123/p/11747304.html