Property
Name |
Title |
Content |
RequestedTheme |
SystemBackdrop |
Foreground |
Background |
BorderBrush |
BorderThickness |
CornerRadius |
FlowDirection |
TitleTemplate |
ContentTemplate |
PrimaryButtonText |
SecondaryButtonText |
CloseButtonText |
IsPrimaryButtonEnabled |
IsSecondaryButtonEnabled |
DefaultButton |
PrimaryButtonStyle |
SecondaryButtonStyle |
CloseButtonStyle |
Events
Name |
PrimaryButtonClick |
SecondaryButtonClick |
CloseButtonClick |
Methods
Example
1 2 3 4 5 6 7 8 9 10 11 12 13
| WindowedContentDialog dialog = new() { Title = "Title", Content = "Content", PrimaryButtonText = "Primary", SecondaryButtonText = "Secondary", CloseButtonText = "Close", OwnerWindow = myWindow, HasTitleBar = true };
ContentDialogResult result = await dialog.ShowAsync(true); var result = result.ToString();
|

Demo
you can run demo and see this feature.