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

SecurityPermissionAttribute.ControlEvidence Property

Gets or sets a value indicating whether permission to alter or manipulate evidence is declared.

[Visual Basic]
Public Property ControlEvidence As Boolean
[C#]
public bool ControlEvidence {get; set;}
[C++]
public: __property bool get_ControlEvidence();
public: __property void set_ControlEvidence(bool);
[JScript]
public function get ControlEvidence() : Boolean;
public function set ControlEvidence(Boolean);

Property Value

true if the ability to alter or manipulate evidence is declared; otherwise, false.

Example

[Visual Basic] 
' Set the Assertion,UnmanagedCode, ControlAppDomain, ControlDomainPolicy, ontrolEvidence, 
' ControlPolicy, ControlPrincipal, ControlThread, Execution, Flags, Infrastructure, 
' RemotingConfiguration, SerializationFormatter, and SkipVerification properties.
<SecurityPermissionAttribute(SecurityAction.Deny, Assertion:=True), _
SecurityPermissionAttribute(SecurityAction.Deny, ControlAppDomain:=True), _
SecurityPermissionAttribute(SecurityAction.Deny, ControlDomainPolicy:=True), _
SecurityPermissionAttribute(SecurityAction.Deny, ControlEvidence:=True), _
SecurityPermissionAttribute(SecurityAction.Deny, ControlPolicy:=True), _
SecurityPermissionAttribute(SecurityAction.Deny, ControlPrincipal:=True), _
SecurityPermissionAttribute(SecurityAction.Deny, ControlThread:=True), _
SecurityPermissionAttribute(SecurityAction.Deny, Execution:=True), _
SecurityPermissionAttribute(SecurityAction.Deny, Flags:=SecurityPermissionFlag.NoFlags), _
SecurityPermissionAttribute(SecurityAction.Deny, Infrastructure:=True), _
SecurityPermissionAttribute(SecurityAction.Deny, RemotingConfiguration:=True), _
SecurityPermissionAttribute(SecurityAction.Deny, SerializationFormatter:=True), _
SecurityPermissionAttribute(SecurityAction.Deny, SkipVerification:=True), _
SecurityPermissionAttribute(SecurityAction.Deny, UnmanagedCode:=True)> _
Public Shared Sub DenySecurityPermissions()

[C#] 
// Set the ControlEvidence property.
    [SecurityPermissionAttribute(SecurityAction.Deny, ControlEvidence = true)] 

[C++] 
// Set the ControlEvidence property.
[SecurityPermissionAttribute(SecurityAction::Deny, ControlEvidence = true)]

[JScript] No example is available for JScript. To view a Visual Basic, C#, or C++ example, click the Language Filter button Language Filter in the upper-left corner of the page.

Requirements

Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

See Also

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

Show:
© 2015 Microsoft