# IChoiceDialogService.Show&lt;T&gt; method

Shows a modal dialog with the given choices.

```csharp
public T Show<T>(string message, string? caption, IReadOnlyList<DialogChoice<T>> choices)
```

| parameter | description |
| --- | --- |
| T | The result type. |
| message | The message text. |
| caption | The window caption. |
| choices | The available choices. The order matches the button order. |

## Return Value

The result of the pressed button, or `default` if the dialog was closed without a choice (by the caption button or Escape).

## See Also

* class [DialogChoice&lt;T&gt;](../DialogChoice-1.md)
* interface [IChoiceDialogService](../IChoiceDialogService.md)
* namespace [Eremex.AvaloniaUI.Controls.ApplicationServices](../index.md)

<!-- DO NOT EDIT: generated by xmldocmd for Eremex.Common.Contracts.dll -->
