/// /// Shows a question-message dialog requesting input from the user. /// /// The text display in the message box /// the value used to initialize the input text field /// Return String that user enter. If no such input given, string with zero length will return public static string Show(String text, String inputText) { SimpleInputDialog simpleDialog = new SimpleInputDialog(text); simpleDialog.inputMessage = inputText; simpleDialog.ShowDialog(); return(simpleDialog.inputMessage); }
/// /// Shows a question-message dialog requesting input from the user. /// /// The text display in the message box /// the value used to initialize the input text field /// The text to display in the title bar of the message box. /// Return String that user enter. If no such input given, string with zero length will return public static string Show(String text, String inputText, String caption) { SimpleInputDialog simpleDialog = new SimpleInputDialog(text); simpleDialog.Text = caption; simpleDialog.inputMessage = inputText; simpleDialog.ShowDialog(); return simpleDialog.inputMessage; }
/// /// Shows a question-message dialog requesting input from the user. /// /// The text display in the message box /// Return String that user enter. If no such input given, string with zero length will return public static string Show(String text) { SimpleInputDialog simpleDialog = new SimpleInputDialog(text); simpleDialog.inputMessage = ""; simpleDialog.ShowDialog(); return simpleDialog.inputMessage; }