Skip to main content

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

ThemedWindow.ShowDialog(MessageBoxButton, Nullable<MessageBoxResult>) Method

Displays the ThemedWindowDialog with the specified MessageBoxButton. A result returned when the window is closed.

Namespace: DevExpress.Xpf.Core

Assembly: DevExpress.Xpf.Core.v24.2.dll

NuGet Package: DevExpress.Wpf.Core

#Declaration

public MessageBoxResult ShowDialog(
    MessageBoxButton dialogButtons,
    MessageBoxResult? defaultButton = null
)

#Parameters

Name Type Description
dialogButtons MessageBoxButton

Buttons to display in the message box.

#Optional Parameters

Name Type Default Description
defaultButton Nullable<MessageBoxResult> null

A default button for the message box.

#Returns

Type Description
MessageBoxResult

The ThemedWindowDialog‘s result value.

#Remarks

The following code snippet shows how to display a ThemedWindowDialog with the OK and Cancel buttons:

ThemedWindow themedWindow = new ThemedWindow() { Title = "ThemedWindowDialog" };
MessageBoxResult result = themedWindow.ShowDialog(MessageBoxButton.OKCancel);
See Also