T
takdick
Unregistered / Unconfirmed
GUEST, unregistred user!
procedure thread1;<br>begin<br>...<br>.......<br>if close=true then //當close為true時<br>begin<br>winexec(pchar(application.exename),sw_normal); //重啟自身程序<br>application.Terminate; //退出程序 //這一動作失效,程序沒有退出<br>end;<br>end;<br><br>h:=beginthread(nil,0,@thread1,nil,0,hid);