关于线程的问题,见者有分!!!! 回复内容

1 楼myy()回复于 2004-06-09 20:21:02

http://www.csdn.net/develop/author/netauthor/raptor/Top

2 楼jacobran()回复于 2004-06-09 21:18:59

运行一下,你就会了.很容易的  
  function   MyThreadFunc(P:pointer):Longint;stdcall;  
  var  
      i:longint;  
      DC:HDC;  
      S:string;  
  begin  
      DC:=GetDC(Form1.Handle);  
      for   i:=0   to   500000   do  
        begin  
            S:=Inttostr(i);  
            Textout(DC,10,10,Pchar(s),length(s));     //屏幕上的字符输出  
        end;  
      ReleaseDC(Form1.Handle,DC);  
  end;  
   
  procedure   TForm1.Button1Click(Sender:   TObject);  
  var  
      hThread:thandle;  
      Threadid:DWord;  
  begin  
      hThread:=CreateThread(nil,0,@mythreadfunc,nil,0,ThreadID);  
      if   hThread   =0   then  
      messagebox(Handle,'Didn’tCreateaThread',nil,MB_OK);  
      end;  
   
  end.Top

3 楼artliu520(arthur)回复于 2004-06-09 21:31:12

visit   www.codeproject.com   about   threads!  
    u'd   better   learn   more   about   computer   network.Top

4 楼zhlwyy(生活很累,但是因为生活才有意义。)回复于 2004-06-09 21:43:19

up一下Top

5 楼zhenpengka(小鸟笨笨)回复于 2004-06-09 22:22:09

UPTop

6 楼mib3000(-_-!!!)回复于 2004-06-10 00:57:25

upTop

7 楼wellsmith(似是故人来)回复于 2004-06-10 01:06:30

so   many   warm-hearted   men!Top