Export (0) Print
Expand All

CodeAccessSecurityAttribute Constructor

Initializes a new instance of CodeAccessSecurityAttribute with the specified SecurityAction.

[Visual Basic]
Public Sub New( _
   ByVal action As SecurityAction _
)
[C#]
public CodeAccessSecurityAttribute(
   SecurityAction action
);
[C++]
public: CodeAccessSecurityAttribute(
   SecurityAction action
);
[JScript]
public function CodeAccessSecurityAttribute(
   action : SecurityAction
);

Parameters

action
One of the SecurityAction values.

Exceptions

Exception Type Condition
ArgumentException The action parameter is not a valid SecurityAction.

Remarks

You cannot create an instance of this class. You must inherit from this class to make use of its functionality.

Notes to Inheritors:  Derived classes must have only one constructor that takes a SecurityAction as its only parameter.

Requirements

Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Common Language Infrastructure (CLI) Standard

See Also

CodeAccessSecurityAttribute Class | CodeAccessSecurityAttribute Members | System.Security.Permissions Namespace

Show:
© 2015 Microsoft