Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

Delphi ×Ô¼ºÐ´¸öTimerÍæÍæ

¼¼Êõ½»Á÷,DH½²½â.
Ã÷ÌìÈ¥×ø»ð³µ,»Ø¼Ò,½ñÌì¾ÍûÓÐÊÂ×ö,±¾À´ÔÚŪһ¸ö¿ç½ø³Ì»ñÈ¡ÆäËû³ÌÐòÀïÃæ×é¼þ,ÈçListView,ListBox,ButtonµÈµÄÐÅÏ¢,ͻȻÓиöÏë·¨×Ô¼ºÐ´¸öTimer,²»ÓÃSetTimerº¯Êý,ÎÒÃÇ×Ô¼ºÓøö¶àÏß³ÌÒ²ÕýºÃʵÏÖÕâ¸ö.·´ÕýÇ°¶Îʱ¼ä¶àÏß³ÌҲŪµÃ±È½Ï¶à,±¾À´Ïëµ¥¶À½²½²µÄ,ÏÖÔÚ¾ÍÓøöÀý×ÓÀ´ËµÃ÷°É.
д³ÉÒ»¸ö¿Ø¼þ:utTimer.pas
view source
< id="highlighter_394362_clipboard" title="copy to clipboard" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="16" height="16" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0" type="application/x-shockwave-flash">
print?
001
unit utTimer;
002
  
003
interface
004
uses
005
  Windows,SysUtils,Classes;
006
  
007
type
008
  THuangJackyTimerThread = class;
009
  THuangJackyTimer = class(TComponent)
010
  private
011
    FTimeInterval:Integer;
012
    FOnTimerDo:TNotifyEvent;
013
    FTimerThread:THuangJackyTimerThread;
014
    FEnable:Boolean;
015
    procedure SetEnable(bBool:Boolean);
016
    procedure SetTimeInterval(aValue:Integer);
017
  
018
    procedure StopThread;
019
    procedure StartThread;
020
  public
021
    constructor Create(AOwner: TComponent); override;
022
    destructor Destroy; override;
023
  published
024
    property TimeInterval:Integer  read FTimeInterval write SetTimeInterval;
025
    property OnTimerDo:TNotifyEvent  read FOnTimerDo write FOnTimerDo;
026
    property Enable:Boolean  read FEnable write SetEnable;
027
  end;
028
  
029
  THuangJackyTimerThread = class(TThread)
030
  private
031
 &nb


Ïà¹ØÎĵµ£º

ÓÃDelphi±àÖÆ¿É×Ô¶¯Éý¼¶³ÌÐò

ÔÚ±àÖÆÁËÒ»¸öÓ¦ÓóÌÐòºóµÄά»¤½×¶Î£¬ÎÒÃÇ»áÃæÁÙ¸øÓ¦ÓóÌÐòÉý¼¶µÄ¹¤×÷.ÎÞÒÉ£¬ÊÖ¹¤Éý¼¶µÄ¹¤×÷ÊÇÊ®·Ö·±ËöµÄ£¬Äã¿ÉÄÜ»áÐèÒªµ½Óû§µÄ»úÆ÷ÉÏÈ¥¸üÐÂÎļþ.¿ÉÊÇ£¬Èç¹ûÄܱàÒ»¸ö×Ô¶¯Éý¼¶³ÌÐò£¬·ÅÔÚÍøÂçÉÏ£¬ÈÃÓû§ÏÂÔØ£¬Ö»ÐèÖ´ÐÐһϾÍÍê³ÉÉý¼¶¹¤×÷£¬²»ÊǺܷ½±ãÂð£¿Æäʵ£¬ÓÃDelphi¿ÉÒԺܷ½±ãµØ±àÖƳöÕâÑùÒ»¸öµÄ³ÌÐò.
ÒÔÏÂÊÇÎÒÃǵÄÀý×Ó£ ......

ÒýÓà [ת]delphi±àÒë´íÎóÖÐÓ¢¶ÔÕÕ±í

ÔÚ±àÒëdelphi³ÌÐòʱ»á³öÏÖÔÚЩÌáʾ£¬È«ÊÇEÎĵģ¬ÏÖÔÚ¸ø´ó¼ÒÒ»¸ö¶ÔÕÕ±í£¬¿ÉÒÔ¸üºÃµÄÀí½â´íÎóÌáʾÐÅÏ¢£¡
';' not allowed before 'ELSE' ElSEÇ°²»ÔÊÐíÓГ;”
'' clause not allowed in OLE automation section ÔÚOLE×Ô¶¯Çø¶Î²»ÔÊÐí“”×Ó¾ä
'' is not a type identifier ²»ÊÇÀàÐͱêʶ·û
'' not prev ......

DelphiÏÂʵÏÖ°üº¬Í¨Åä·ûµÄÎı¾²éÕÒ

±¾ÎÄ×îÔçÔÚ±à³ÌÂÛ̳ÉÏ·¢±í£¬ÎÄÕµØÖ·£ºhttp://programbbs.com/bbs/view12-21351-1.htm£¬Ïà¹ØÎļþ¿ÉÒÔÔÚÉÏÊöµØÖ·µÄÒ³ÃæÖÐÏÂÔØ¡£×ªÔØʱÇë×¢Ã÷³ö´¦¡£
Ò»¡¢Ç°ÑÔ
ͨÅä·û¾ÍÊÇÖ¸“*”ºÍ“?”Á½¸ö×Ö·û£¬“*”±íʾµ±Ç°Î»ÖÿÉÒÔûÓлòÕßÓжà¸öÈÎÒâ×Ö·û£»“?”±íʾµ±Ç°Î»ÖÃÓÐÒ»¸öÈÎÒâ×Ö·û¡£ ......

Delphi ¶¯Ì¬´´½¨´°¿ÚµÄ¼¸ÖÖ·½·¨

  ·½·¨1£º¿ÉдΪº¯Êý£¬ÔÙµ÷ÓÃ
  Application.CreateForm(TForm1, Form1);
  Form1.ShowModal;
  Form1.Free;
  ·½·¨2£º
  Form1:= TForm1.Create(Application);
  try
     Form1.ShowModal;
  finally
     ......

ÓÃSPCOMM ÔÚ DelphiÖÐʵÏÖ´®¿ÚͨѶ

ÓÃDelphi ʵÏÖ´®¿ÚͨѶ£¬³£Óõļ¸ÖÖ·½·¨Îª£ºÊ¹ÓÿؼþÈçMSCOMMºÍSPCOMM£¬Ê¹ÓÃAPIº¯Êý»òÕßÔÚDelphi Öе÷ÓÃÆäËü´®¿ÚͨѶ³ÌÐò¡£ÀûÓÃAPI±àд´®¿ÚͨÐųÌÐò½ÏΪ¸´ÔÓ£¬ÐèÒªÕÆÎÕ´óÁ¿Í¨ÐÅ֪ʶ£¬ÆäÓŵãÊÇ¿ÉʵÏֵŦÄܸüÇ¿´ó£¬Ó¦ÓÃÃæ¸ü¹ã·º£¬¸üÊʺÏÓÚ±àд½ÏΪ¸´ÔÓ µÄµÍ²ã´ÎͨÐųÌÐò¡£Ïà±È½Ï¶øÑÔ£¬ÀûÓÃSPComm¿Ø¼þÔòÏà¶Ô½Ï¼òµ¥£¬¸Ã¿Ø¼þ¾ßÓ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ