Class PromptExtensions
Extension methods for prompting users with views in modal dialogs.
public static class PromptExtensions
- Inheritance
-
PromptExtensions
- Inherited Members
Remarks
These extensions provide convenient ways to show any View in a modal dialog with Ok/Cancel buttons and get a typed result.
Two API styles are provided:
- Prompt<TView, TResult>(IRunnable, TView?, Func<TView, TResult?>?, TResult?, Action<Prompt<TView, TResult>>?) on IRunnable - For C# with type-safe result extraction and hosting relationship
- Prompt<TView>(IApplication, TView) on IApplication - For scripting languages, returns string?.
For detailed usage patterns, customization options, and PowerShell examples, see the Prompt Deep Dive.
Methods
- Prompt<TView>(IApplication, TView)
Shows a view in a modal dialog with Ok/Cancel buttons. For scripting languages.
- Prompt<TView, TResult>(IRunnable, TView?, Func<TView, TResult?>?, TResult?, Action<Prompt<TView, TResult>>?)
Shows a view in a modal dialog with Ok/Cancel buttons and extracts a typed result.