MessageDlg (C++)

From RAD Studio Code Examples
Jump to: navigation, search

Description

This example uses a button on a form. When you click the button, an error type message box appears with Yes, No, and Cancel buttons on it.

Code

void __fastcall TForm4::Button1Click(TObject *Sender) {
	UnicodeString errorText = "This is a sample message for an error";
        MessageDlg(errorText,mtError,mbAbortRetryIgnore,0);
}

Uses

See Also