Z
zylsoft
Unregistered / Unconfirmed
GUEST, unregistred user!
type
meThread=class(TThread)
private
{ Private declarations }
protected
procedure Execute;
override;
end;
var
Form1: TForm1;
MyThread:TThread;
procedure meThread.Execute;
begin
//FreeOnTerminate:=true;
执行的代码
//form1.Memo1.Lines.Add('测试');
end;
procedure TForm1.Button1Click(Sender: TObject);
begin
if MyThread=nil then
begin
MyThread:=meThread.Create(false);
end;
end;
代码部分路上,怎样让meThread执行完一次后停1分钟后再从头执行,就是让线程间隔1分钟反复执行?
meThread=class(TThread)
private
{ Private declarations }
protected
procedure Execute;
override;
end;
var
Form1: TForm1;
MyThread:TThread;
procedure meThread.Execute;
begin
//FreeOnTerminate:=true;
执行的代码
//form1.Memo1.Lines.Add('测试');
end;
procedure TForm1.Button1Click(Sender: TObject);
begin
if MyThread=nil then
begin
MyThread:=meThread.Create(false);
end;
end;
代码部分路上,怎样让meThread执行完一次后停1分钟后再从头执行,就是让线程间隔1分钟反复执行?