Language

RegistryPreference Constructor (Domain, Guid, Boolean, Boolean)

 

Initializes a new instance of the RegistryPreference class by using the specified Domain, 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)

Syntax

public RegistryPreference(
    Domain domain,
    Guid gpoId,
    bool computerConfiguration,
    bool readOnly
)
public:
RegistryPreference(
    Domain^ domain,
    Guid gpoId,
    bool computerConfiguration,
    bool readOnly
)
new : 
        domain:Domain *
        gpoId:Guid *
        computerConfiguration:bool *
        readOnly:bool -> RegistryPreference
Public Sub New (
    domain As Domain,
    gpoId As Guid,
    computerConfiguration As Boolean,
    readOnly As Boolean
)

Parameters

  • computerConfiguration
    Type: System.Boolean

    true to edit Computer Configuration; false to edit User Configuration.

  • readOnly
    Type: System.Boolean

    true to open the GPO in read-only mode; otherwise, false.

See Also

RegistryPreference Overload
RegistryPreference Class
Microsoft.GroupPolicy Namespace

Return to top