Class DialogResult
- Namespace
- MudBlazor
- Assembly
- MudBlazor.dll
The result of a user's interaction with a MudDialog.
public class DialogResult
- Inheritance
-
DialogResult
- Inherited Members
- Extension Methods
Constructors
DialogResult(object?, Type?, bool)
protected DialogResult(object? data, Type? resultType, bool canceled)
Parameters
Properties
Canceled
Indicates whether the user clicked a cancel button.
public bool Canceled { get; }
Property Value
Data
The data included with the result.
public object? Data { get; }
Property Value
Remarks
This value is typically a custom object related to the dialog, such as the object which will be affected by the user's response.
DataType
The type of object in the Data property.
public Type? DataType { get; }
Property Value
Methods
Cancel()
The result when the user clicks the cancel button.
public static DialogResult Cancel()
Returns
- DialogResult
The dialog result.
Ok<T>(T)
The result when the user clicks the Ok button.
public static DialogResult Ok<T>(T result)
Parameters
result
TThe value included.
Returns
- DialogResult
The dialog result.
Type Parameters
T
The type of result included.
Ok<T>(T, Type?)
The result when the user clicks the Ok button.
public static DialogResult Ok<T>(T result, Type? dialogType)
Parameters
result
TThe value included.
dialogType
TypeThe type of dialog which the user responded to.
Returns
- DialogResult
The dialog result.
Type Parameters
T
The type of result included.