本文整理自网络,侵删。
//the system time of you PC has changed. unit Unit1; interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, StdCtrls; type TForm1 = class(TForm) Button1: TButton; procedure Button1Click(Sender: TObject); private procedure WMTIMECHANGE(var message: TWMTIMECHANGE); message WM_TIMECHANGE; { Private declarations } public { Public declarations } end; var Form1: TForm1; implementation {$R *.dfm} procedure TForm1.Button1Click(Sender: TObject); begin close; end; procedure TForm1.WMTIMECHANGE(var message: TWMTIMECHANGE); begin ShowMessage('Time changed'); end; end.
相关阅读 >>
Delphi 10.3 中安装程序自动升级插件autoupgrader_pro_v5.2
更多相关阅读请进入《Delphi》频道 >>