PolicyLevel::ChangeNamedPermissionSet Method (String^, PermissionSet^)

 

Replaces a NamedPermissionSet in the current policy level with the specified PermissionSet.

Namespace:   System.Security.Policy
Assembly:  mscorlib (in mscorlib.dll)

public:
NamedPermissionSet^ ChangeNamedPermissionSet(
	String^ name,
	PermissionSet^ pSet
)

Parameters

name
Type: System::String^

The name of the NamedPermissionSet to replace.

pSet
Type: System.Security::PermissionSet^

The PermissionSet that replaces the NamedPermissionSet specified by the name parameter.

Return Value

Type: System.Security::NamedPermissionSet^

A copy of the NamedPermissionSet that was replaced.

Exception Condition
ArgumentNullException

The name parameter is null.

-or-

The pSet parameter is null.

ArgumentException

The name parameter is equal to the name of a reserved permission set.

-or-

The PermissionSet specified by the pSet parameter cannot be found.

.NET Framework
Available since 1.1
Return to top
Show: