Class InputBox
Shows a simple dialog asking the user to input some text.
Namespace: NanoByte.Common.Controls
Assembly: NanoByte.Common.WinForms.dll
Syntax
public sealed class InputBox : Form
Methods
Dispose(Boolean)
Clean up any resources being used.
Declaration
protected override void Dispose(bool disposing)
Parameters
Type | Name | Description |
---|---|---|
Boolean | disposing | true if managed resources should be disposed; otherwise, false. |
Show(IWin32Window, String, String, String, Boolean)
Displays an input box asking the the user to input some text.
Declaration
public static string Show(IWin32Window owner, string title, string prompt, string defaultText = null, bool password = false)
Parameters
Type | Name | Description |
---|---|---|
IWin32Window | owner | The parent window the displayed window is modal to; can be |
String | title | The window title to use. |
String | prompt | The prompt to display. |
String | defaultText | The default text to show pre-entered in the input field. |
Boolean | password | Shall the input characters be hidden as a password? |
Returns
Type | Description |
---|---|
String | The text the user entered if she pressed OK; otherwise |