...meinen eigenen Hilfe Dialog anzeigen, wenn der Benutzer auf das biHelp Icon klickt?
Autor: P. Below
type
TForm1 = class(TForm)
private
procedure wmNCLButtonDown(var Msg: TWMNCLButtonDown); message WM_NCLBUTTONDOWN;
procedure wmNCLButtonUp(var Msg: TWMNCLButtonUp); message WM_NCLBUTTONUP;
end;
var
Form1: TForm1;
implementation
{$R *.DFM}
procedure TForm1.wmNCLButtonDown(var Msg: TWMNCLButtonDown);
begin
if Msg.HitTest = HTHELP then
begin
Msg.Result := 0; // swallow mouse down on biHelp border icon
end
else
inherited;
end;
procedure TForm1.wmNCLButtonUp(var Msg: TWMNCLButtonUp);
begin
if Msg.HitTest = HTHELP then
begin
Msg.Result := 0;
ShowMessage('Hi!'); // Show your help here
end
else
inherited;
end;
printed from
www.swissdelphicenter.ch
developers knowledge base