去看‘防止关闭windows’Delphi文档,把消息替换即可!
解决方案 »
- 求一段直接赋值的代码!?
- 请问如何把Memo里的每一行内容转换为2进制然后存入TMemoryStream里?谢谢
- 怎样通过Delphi编程获取USB CA证书内容?用什么组件或API函数?谢谢大家!请高人指点!分数不够再加分!
- Access导入到sql server2000中,怎么导啊,在线,马上给分
- 在循环中触发事件应该怎么办??呵呵
- delphi7用ClientDataSet联接interbase7.1,出现“Operation not applicable”错误,delphi7不支持吗?
- 求教:给家里装个监控摄像头,需要在远处网上能看到家里的情况
- 各位帮忙介绍本Delphi好书吧!
- 这个数据问题还没有解决呀,请求大虾帮忙
- 如何取得硬盘的序列号
- delphi6的安装程序是用什么软件做的?
- Help me!Help me!Help me!Help me!Help me!Help me!Help me!Help me!Help me!Help me!
Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
StdCtrls;type
TBNClose = class(TForm)
Button1: TButton;
procedure Button1Click(Sender: TObject);
private
procedure WMDestroy(var msg: TMsg); message WM_DESTROY;
public
{ Public declarations }
end;var
BNClose: TBNClose;implementation{$R *.DFM}{ TBNClose }procedure TBNClose.WMDestroy(var msg: TMsg);
begin
{此处加入想要执行的过程}
inherited;
end;procedure TBNClose.Button1Click(Sender: TObject);
begin
Close;
end;end.
unit Unit1;interfaceuses
Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
StdCtrls;type
TFMTest = class(TForm)
BNClose: TButton;
procedure BNCloseClick(Sender: TObject);
private
procedure WMDestroy(var msg: TMsg); message WM_DESTROY;
public
{ Public declarations }
end;var
FMTest: TFMTest;implementation{$R *.DFM}{ TBNClose }procedure TFMTest.WMDestroy(var msg: TMsg);
begin
{此处加入想要执行的过程}
inherited;
end;procedure TFMTest.BNCloseClick(Sender: TObject);
begin
Close;
end;end.