GroupPolicyExtension Constructor (Domain, String)

Initializes a new instance of the GroupPolicyExtension class by using the specified Domain and the display name of the Group Policy object (GPO).

Namespace: Microsoft.GroupPolicy
Assembly: Microsoft.GroupPolicy.Management (in microsoft.grouppolicy.management.dll)

Usage

    Dim domain As Domain
Dim gpoDisplayName As String

Dim instance As New GroupPolicyExtension(domain, gpoDisplayName)

Syntax

'Declaration
Protected Sub New ( _
    domain As Domain, _
    gpoDisplayName As String _
)
protected GroupPolicyExtension (
    Domain domain,
    string gpoDisplayName
)
protected:
GroupPolicyExtension (
    Domain^ domain, 
    String^ gpoDisplayName
)
protected GroupPolicyExtension (
    Domain domain, 
    String gpoDisplayName
)
protected function GroupPolicyExtension (
    domain : Domain, 
    gpoDisplayName : String
)

Parameters

  • domain
    A Domain that represents the domain of the GPO.
  • gpoDisplayName
    The display name of the GPO to edit.

Exceptions

Exception type Condition
ArgumentNullException

domain is null.

ActiveDirectoryObjectNotFoundException

The GPO is not found.

MultipleGroupPolicyObjectsFoundException

Multiple GPOs with the specified display name exist in the domain.

Platforms

Development Platforms

Windows Server 2008 R2

Target Platforms

Windows Server 2008 R2

See Also

Reference

GroupPolicyExtension Class
GroupPolicyExtension Members
Microsoft.GroupPolicy Namespace