SPListItem.DoesUserHavePermissions method (SPUser, SPBasePermissions)

Indicates whether the specified user has the specified permissions on an item.

Namespace:  Microsoft.SharePoint
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)

public bool DoesUserHavePermissions(
	SPUser user,
	SPBasePermissions permissionMask
)

Parameters

user
Type: Microsoft.SharePoint.SPUser

An SPUser object that represents information about the user.

permissionMask
Type: Microsoft.SharePoint.SPBasePermissions

An SPBasePermissions value that specifies permissions for the item.

Return value

Type: System.Boolean
true if the user has the permissions; otherwise, false.
Show: