Uri.UserEscaped Property

Indicates that the URI string was completely escaped before the Uri instance was created.

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

public bool UserEscaped { get; }

Property Value

Type: System.Boolean
A Boolean value that is true if the dontEscape parameter was set to true when the Uri instance was created; otherwise, false.

The UserEscaped property is set to true to indicate that the string used to create the Uri instance was completely escaped before it was passed to the constructor; that is, the dontEscape parameter of the constructor call was set to true.

The following example creates a Uri instance and determines whether it was fully escaped when it was created.


        Uri uriAddress3 = new Uri ("http://user:password@www.contoso.com/index.htm ");
        outputBlock.Text += uriAddress3.UserInfo;
        outputBlock.Text += "\n";

        if (uriAddress.UserEscaped)
            outputBlock.Text += "Fully Escaped yes\n";
        else    
            outputBlock.Text += "Fully Escaped no\n";



Windows Phone OS

Supported in: 8.1, 8.0, 7.1, 7.0

Windows Phone

Show:
© 2015 Microsoft