DnsPermission Constructor
Collapse the table of content
Expand the table of content

DnsPermission Constructor (PermissionState)


Creates a new instance of the DnsPermission class that either allows unrestricted DNS access or disallows DNS access.

Namespace:   System.Net
Assembly:  System (in System.dll)

new : 
        state:PermissionState -> DnsPermission


Type: System.Security.Permissions.PermissionState

One of the PermissionState values.

Exception Condition

state is not a valid PermissionState value.

If state is Unrestricted, the DnsPermission instance passes all demands. If state contains any other value, the DnsPermission instance fails all demands.

Legacy Code Example

The following example creates an instance of the DnsPermission class.

No code example is currently available or this language may not be supported.

.NET Framework
Available since 1.1
Return to top
© 2015 Microsoft