MessageBox class¶
Attributes: [ToolboxItem(true)] [ToolboxBitmap]
Defined in
Namespace: CrissCross.WPF.UI.Controls
Assembly: CrissCross.WPF.UI.dll
Full name: CrissCross.WPF.UI.Controls.MessageBox
Modifiers: public
Summary¶
Customized window for notifications.
Applies to
net10.0-windows10.0.19041, net9.0-windows10.0.19041, net8.0-windows10.0.19041, net481
Class hierarchy
classDiagram
class MessageBox
class Window
Window <|-- MessageBox
Inherits from: Window
Constructors¶
| Name | Summary |
|---|---|
| .ctor | Initializes a new instance of the [MessageBox](# class. |
Properties¶
| Name | Summary |
|---|---|
| ShowTitle | Gets or sets a value indicating whether to show the Title in [TitleBar](# |
| PrimaryButtonText | Gets or sets the text to display on the primary button. |
| SecondaryButtonText | Gets or sets the text to be displayed on the secondary button. |
| CloseButtonText | Gets or sets the text to display on the close button. |
| PrimaryButtonIcon | Gets or sets the [SymbolRegular](# on the primary button. |
| SecondaryButtonIcon | Gets or sets the [SymbolRegular](# on the secondary button. |
| CloseButtonIcon | Gets or sets the [SymbolRegular](# on the close button. |
| PrimaryButtonAppearance | Gets or sets the [ControlAppearance](# on the primary button. |
| SecondaryButtonAppearance | Gets or sets the [ControlAppearance](# on the secondary button. |
| CloseButtonAppearance | Gets or sets the [ControlAppearance](# on the close button. |
| IsSecondaryButtonEnabled | Gets or sets a value indicating whether the [MessageBox](# primary button is enabled. |
| IsPrimaryButtonEnabled | Gets or sets a value indicating whether the [MessageBox](# secondary button is enabled. |
| TemplateButtonCommand | Gets the command triggered after clicking the button on the Footer. |
| Tcs | Gets or sets the TCS. |
| OnButtonClickCommand | Occurs after the [MessageBoxButton](# is clicked. |
Fields¶
| Name | Summary |
|---|---|
| static ShowTitleProperty | Identifies the [ShowTitle](# dependency property. |
| static PrimaryButtonTextProperty | Identifies the [PrimaryButtonText](# dependency property. |
| static SecondaryButtonTextProperty | Identifies the [SecondaryButtonText](# dependency property. |
| static CloseButtonTextProperty | Identifies the [CloseButtonText](# dependency property. |
| static PrimaryButtonIconProperty | Identifies the [PrimaryButtonIcon](# dependency property. |
| static SecondaryButtonIconProperty | Identifies the [SecondaryButtonIcon](# dependency property. |
| static CloseButtonIconProperty | Identifies the [CloseButtonIcon](# dependency property. |
| static PrimaryButtonAppearanceProperty | Identifies the [PrimaryButtonAppearance](# dependency property. |
| static SecondaryButtonAppearanceProperty | Identifies the [SecondaryButtonAppearance](# dependency property. |
| static CloseButtonAppearanceProperty | Identifies the [CloseButtonAppearance](# dependency property. |
| static IsPrimaryButtonEnabledProperty | Identifies the [IsPrimaryButtonEnabled](# dependency property. |
| static IsSecondaryButtonEnabledProperty | Identifies the [IsSecondaryButtonEnabled](# dependency property. |
| static TemplateButtonCommandProperty | Identifies the [TemplateButtonCommand](# dependency property. |
Methods¶
| Name | Summary |
|---|---|
| Show | Shows this instance. |
| ShowDialog | Shows the dialog. |
| Close | Closes this instance. |
| ShowDialogAsync | Displays a message box. |
| OnLoaded | Occurs after Loading event. |
| ResizeToContentSize | Resizes the MessageBox to fit the content's size, including margins. |
| OnClosing | Raises the Closing event. |
| CenterWindowOnScreen | Centers the window on screen. |
| OnButtonClick | Occurs after the [MessageBoxButton](# is clicked. |