RegistryPreference Constructor (DomainController, Guid, Boolean, Boolean)
Initializes a new instance of the RegistryPreference class by using the specified DomainController, the specified Group Policy object (GPO) ID (GUID), a value that specifies whether to edit Computer Configuration or User Configuration, and a value that specifies whether to open the GPO in read-only mode.
Namespace: Microsoft.GroupPolicy
Assembly: Microsoft.GroupPolicy.Management (in microsoft.grouppolicy.management.dll)
Usage
Dim domainController As DomainController
Dim gpoId As Guid
Dim computerConfiguration As Boolean
Dim readOnly As Boolean
Dim instance As New RegistryPreference(domainController, gpoId, computerConfiguration, readOnly)
Syntax
'Declaration
Public Sub New ( _
domainController As DomainController, _
gpoId As Guid, _
computerConfiguration As Boolean, _
readOnly As Boolean _
)
public RegistryPreference (
DomainController domainController,
Guid gpoId,
bool computerConfiguration,
bool readOnly
)
public:
RegistryPreference (
DomainController^ domainController,
Guid gpoId,
bool computerConfiguration,
bool readOnly
)
public RegistryPreference (
DomainController domainController,
Guid gpoId,
boolean computerConfiguration,
boolean readOnly
)
public function RegistryPreference (
domainController : DomainController,
gpoId : Guid,
computerConfiguration : boolean,
readOnly : boolean
)
Parameters
- domainController
A DomainController object that represents the domain controller to use.
- gpoId
The GUID of the GPO to edit.
- computerConfiguration
true to edit Computer Configuration; false to edit User Configuration.
- readOnly
true to open the GPO in read-only mode; otherwise, false.
Platforms
Development Platforms
Windows Server 2008 R2
Target Platforms
Windows Server 2008 R2
See Also
Reference
RegistryPreference Class
RegistryPreference Members
Microsoft.GroupPolicy Namespace