Einzelnen Beitrag anzeigen

LOMBI
(Gast)

n/a Beiträge
 
#1

Messagebox mit farbigen TEButtons ...

  Alt 1. Jul 2010, 11:05
Hallo,

wie bitte lassen sich in nachstehender Funktion die "normalen" Buttons durch farbige TEButtons ersetzen?

Delphi-Quellcode:
function MessageDlgPosC(const Msg: string; AType:
         TMsgDlgType; EButtons:
         TMsgDlgButtons; HelpCtx: Longint; X, Y: Integer): Word;
begin
  with CreateMessageDialog(Msg, AType, EButtons) do begin
    case AType of
     mtWarning: Color := $0080FFFF;
     mtError: Color := $007171FF;
     mtInformation: Color := $00CAFFCA;
     mtConfirmation: Color := $00FFB9B9;
     mtCustom: Color := clBtnFace;
     else Color := clBtnFace;
    end;

    Caption := 'Hinweis';

    Left := X;
    Top := Y;
    Result := ShowModal;
  end;
end;
Vielen Dank vorab für Hilfe!

Gruß
Lombi
  Mit Zitat antworten Zitat