IObjectPermission.Deny IObjectPermission.Deny IObjectPermission.Deny Method

Definition

Denies access to the specified permission for the specified grantees on the SMO object.

Overloads

Deny(ObjectPermissionSet, String) Deny(ObjectPermissionSet, String) Deny(ObjectPermissionSet, String)

Denies access to the specified permission for the specified grantee on the SMO object.

Deny(ObjectPermissionSet, String[]) Deny(ObjectPermissionSet, String[]) Deny(ObjectPermissionSet, String[])

Denies access to the specified permission for the specified grantees on the SMO object.

Deny(ObjectPermissionSet, String, Boolean) Deny(ObjectPermissionSet, String, Boolean) Deny(ObjectPermissionSet, String, Boolean)

Denies access to the specified permission for the specified grantee and other users that the grantee granted access on the SMO object.

Deny(ObjectPermissionSet, String[], Boolean) Deny(ObjectPermissionSet, String[], Boolean) Deny(ObjectPermissionSet, String[], Boolean)

Denies access to the specified permission for the specified grantees on the SMO object.

Deny(ObjectPermissionSet, String) Deny(ObjectPermissionSet, String) Deny(ObjectPermissionSet, String)

Denies access to the specified permission for the specified grantee on the SMO object.

public:
 void Deny(Microsoft::SqlServer::Management::Smo::ObjectPermissionSet ^ permissions, System::String ^ granteeName);
public void Deny (Microsoft.SqlServer.Management.Smo.ObjectPermissionSet permissions, string granteeName);
Public Sub Deny (permissions As ObjectPermissionSet, granteeName As String)
Parameters
permissions
ObjectPermissionSet ObjectPermissionSet ObjectPermissionSet

An ObjectPermissionSet object value that specifies the permission.

granteeName
String String String

A String value that specifies the grantee to be denied access to the permission.

Deny(ObjectPermissionSet, String[]) Deny(ObjectPermissionSet, String[]) Deny(ObjectPermissionSet, String[])

Denies access to the specified permission for the specified grantees on the SMO object.

public:
 void Deny(Microsoft::SqlServer::Management::Smo::ObjectPermissionSet ^ permissions, cli::array <System::String ^> ^ granteeNames);
public void Deny (Microsoft.SqlServer.Management.Smo.ObjectPermissionSet permissions, string[] granteeNames);
Public Sub Deny (permissions As ObjectPermissionSet, granteeNames As String())
Parameters
permissions
ObjectPermissionSet ObjectPermissionSet ObjectPermissionSet

An ObjectPermissionSet object value that specifies the permission.

granteeNames
String[]

A String array that specifies a list of grantees to be denied access to the permission.

Deny(ObjectPermissionSet, String, Boolean) Deny(ObjectPermissionSet, String, Boolean) Deny(ObjectPermissionSet, String, Boolean)

Denies access to the specified permission for the specified grantee and other users that the grantee granted access on the SMO object.

public:
 void Deny(Microsoft::SqlServer::Management::Smo::ObjectPermissionSet ^ permissions, System::String ^ granteeName, bool cascade);
public void Deny (Microsoft.SqlServer.Management.Smo.ObjectPermissionSet permissions, string granteeName, bool cascade);
Public Sub Deny (permissions As ObjectPermissionSet, granteeName As String, cascade As Boolean)
Parameters
permissions
ObjectPermissionSet ObjectPermissionSet ObjectPermissionSet

An ObjectPermissionSet object value that specifies the permission.

granteeName
String String String

A String value that specifies the grantee to be denied access to the permission.

cascade
Boolean Boolean Boolean

A Boolean property that specifies whether users that the grantee has granted access to the permission are also denied access to the permission.

If True, the grantee and users to which the grantee granted access to the permission are all denied access to the permission.

If False, only the grantee is denied access to the permission.

Deny(ObjectPermissionSet, String[], Boolean) Deny(ObjectPermissionSet, String[], Boolean) Deny(ObjectPermissionSet, String[], Boolean)

Denies access to the specified permission for the specified grantees on the SMO object.

public:
 void Deny(Microsoft::SqlServer::Management::Smo::ObjectPermissionSet ^ permissions, cli::array <System::String ^> ^ granteeNames, bool cascade);
public void Deny (Microsoft.SqlServer.Management.Smo.ObjectPermissionSet permissions, string[] granteeNames, bool cascade);
Public Sub Deny (permissions As ObjectPermissionSet, granteeNames As String(), cascade As Boolean)
Parameters
permissions
ObjectPermissionSet ObjectPermissionSet ObjectPermissionSet

An ObjectPermissionSet object value that specifies the permission.

granteeNames
String[]

A String array that specifies a list of grantees to be denied access to the permission.

cascade
Boolean Boolean Boolean

A Boolean property that specifies whether users that the grantee has granted access to the permission are also denied access to the permission.

If True, the grantee and users to which the grantee granted access to the permission are all denied access to the permission.

If False, only the grantee is denied access to the permission.

Applies to