Udostępnij za pośrednictwem


DataServiceContext.UseDefaultCredentials Property

Gets or sets whether default credentials are used to authenticate requests to the data service.

Supported only by the WCF Data Services 5.0 client for Silverlight.

Namespace:  System.Data.Services.Client
Assembly:  Microsoft.Data.Services.Client.SL (in Microsoft.Data.Services.Client.SL.dll)

Syntax

'Declaration
Public Property UseDefaultCredentials As Boolean 
    Get 
    Set
'Usage
Dim instance As DataServiceContext 
Dim value As Boolean 

value = instance.UseDefaultCredentials

instance.UseDefaultCredentials = value
public bool UseDefaultCredentials { get; set; }
public:
property bool UseDefaultCredentials {
    bool get ();
    void set (bool value);
}
member UseDefaultCredentials : bool with get, set
function get UseDefaultCredentials () : boolean 
function set UseDefaultCredentials (value : boolean)

Property Value

Type: System.Boolean
true when the default credentials should be used; otherwise false.

Remarks

Set this property to true when requests made by this DataServiceContext instance should, when it is requested by the server, be authenticated using the credentials of the currently logged on user.

See Also

Reference

DataServiceContext Class

System.Data.Services.Client Namespace