ThemedInputBox dialog
The ThemedInputBox is a dialog that provides a message and a TextBox so that the user can enter text.

Properties
None.
Methods
Show(string message, string title, string defaultValue = "")
Shows a modal dialog using the current theme. Returns a string?.
If the returned value is null, it means that the user selected the Cancel button or closed the dialog.
Arguments
stringmessage : The message to display.stringtitle : The title of the dialog.stringdefaultValue : The text to write in theTextBoxby default when the dialog opens.
Show(string message, string title, string defaultValue, string defaultButtonText, string secondaryButtonText)
Shows a modal dialog using the current theme. Returns a string?.
If the returned value is null, it means that the user selected the Cancel button or closed the dialog.
Arguments
stringmessage : The message to display.stringtitle : The title of the dialog.stringdefaultValue : The text to write in theTextBoxby default when the dialog opens.stringdefaultButtonText : The text to display in the default button.stringsecondaryButtonText : The text to in the the secondary button.
Show(string message, string title, Window owner, string defaultValue = "", string? defaultButtonText = null, string? secondaryButtonText = null
Shows a modal dialog using the current theme. Returns a MessageBoxResult that represents the choice of the user.
This method can be used to override the default texts and provide a better UX while still using the default framework components.
This method should be used with the MessageBoxButton.YesNoCancel or MessageBoxButton.YesNo arguments. The Yes button will be replaced with the defaultButtonText value, and the No button will be replaced with the secondaryButtonText.
Arguments
stringmessage : The message to display.stringtitle : The title of the dialog.Windowowner : The window that owns the dialog; used for the modal behavior.stringdefaultValue : The text to write in theTextBoxby default when the dialog opens.stringdefaultButtonText : The text to display in the default button.stringsecondaryButtonText : The text to in the the secondary button.
Events
None.
Examples
Example 1
This example shows how to use the ThemedInputBox from C# and handle the result.
string? value = ThemedInputBox.Show("Please provide name for this folder:", "Rename folder", this);
if (!string.IsNullOrEmpty(value))
{
// some code to rename a folder
}