【发布时间】:2015-03-21 10:58:46
【问题描述】:
在 Delphi XE7 中,我需要使用 MessageBox 中的帮助按钮。 MSDN 状态:
MB_HELP 0x00004000L 向消息框添加帮助按钮。当。。。的时候 用户点击帮助按钮或按 F1,系统发送 WM_HELP 给主人留言。
但是,当我单击 MessageBox 中的帮助按钮时,似乎没有向应用程序发送 WM_HELP 消息:
procedure TForm1.ApplicationEvents1Message(var Msg: tagMSG; var Handled: Boolean);
begin
if Msg.message = WM_HELP then
CodeSite.Send('ApplicationEvents1Message WM_HELP');
end;
procedure TForm1.btnShowMessageBoxClick(Sender: TObject);
begin
MessageBox(Self.Handle, 'Let''s test the Help button.', 'Test', MB_ICONINFORMATION or MB_OK or MB_HELP);
end;
那么我怎样才能让 MessageBox 帮助按钮点击,我怎样才能检测到它来自哪个 MessageBox?
【问题讨论】:
标签: delphi messagebox delphi-xe7