Export (0) Print
Expand All

HtmlWindow.Prompt Method

Silverlight

Displays a dialog box that prompts the user with a message and an input field.

Namespace:  System.Windows.Browser
Assembly:  System.Windows.Browser (in System.Windows.Browser.dll)

public string Prompt(
	string promptText
)

Parameters

promptText
Type: System.String
Message to display in the dialog box.

Return Value

Type: System.String
The user's input.

This method is equivalent to the JavaScript prompt method. It displays the string specified by the promptText parameter and returns a string that contains the user's input.

This method allows null and empty strings for promptText. A null reference is turned into an empty string.

For more information about this method, see the prompt method in the dynamic HTML (DHTML) documentation.

Silverlight

Supported in: 5, 4, 3

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.

Community Additions

ADD
Show:
© 2014 Microsoft