IntranetZoneCredentialPolicy 构造函数

定义

初始化 IntranetZoneCredentialPolicy 类的新实例。Initializes a new instance of the IntranetZoneCredentialPolicy class.

public:
 IntranetZoneCredentialPolicy();
public IntranetZoneCredentialPolicy ();
Public Sub New ()

示例

下面的代码示例演示如何创建此类的实例。The following code example demonstrates creating an instance of this class.

static void UseIntranetCredentialPolicy()
{
   IntranetZoneCredentialPolicy^ policy = gcnew IntranetZoneCredentialPolicy;
   AuthenticationManager::CredentialPolicy = policy;
}
 public static void UseIntranetCredentialPolicy()
{
    IntranetZoneCredentialPolicy  policy = new IntranetZoneCredentialPolicy();
    AuthenticationManager.CredentialPolicy = policy;
}

注解

应用程序使用此构造函数来创建可用于设置CredentialPolicy属性的对象。Applications use this constructor to create objects that can be used to set the CredentialPolicy property.

适用于