Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All

CodeGroup Constructor

Initializes a new instance of CodeGroup.

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

protected CodeGroup (
	IMembershipCondition membershipCondition,
	PolicyStatement policy
)
protected CodeGroup (
	IMembershipCondition membershipCondition, 
	PolicyStatement policy
)
protected function CodeGroup (
	membershipCondition : IMembershipCondition, 
	policy : PolicyStatement
)

Parameters

membershipCondition

A membership condition that tests evidence to determine whether this code group applies policy.

policy

The policy statement for the code group in the form of a permission set and attributes to grant code that matches the membership condition.

Exception typeCondition

ArgumentNullException

The membershipCondition parameter is a null reference (Nothing in Visual Basic).

ArgumentException

The type of the membershipCondition parameter is not valid.

-or-

The type of the policy parameter is not valid.

This constructor creates a basic code group and should be called from the constructors of custom code groups. You can add child code groups using the AddChild method.

Windows 98, Windows 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see System Requirements.

.NET Framework

Supported in: 2.0, 1.1, 1.0

Community Additions

ADD
Show:
© 2015 Microsoft