3

I need to create a permission level for allowing to add only in document library. The issue is when i add permission: Add items, it checkes automatically View Items

I'm n sandbox solution so i don't have powershell

thanks

1
  • SharePoint grants you permission to view the items which you have created in the document libraries. Do you want to restrict users from seeing each others items, while they can add items?
    – Sudhakar
    Jul 7, 2014 at 9:20

4 Answers 4

1

This is not possible. SharePoint expects user to have permissions to view those items which are added by the user.

However, If you want to ensure privacy by not letting users to view others items then go to List/Document Library Settings -> Advanced Settings and then set options for Read Access as "Read items that were created by the user".

3
  • thanks but it's not enough because i've some folder in my lib and depending on the folder he can see all items or not Jul 7, 2014 at 13:58
  • I think you will have to create different document libraries if you have to secure documents in your case.
    – Sudhakar
    Jul 8, 2014 at 6:10
  • thanks for your replies, i let the user see documents because of use of sanbox. Jul 8, 2014 at 6:48
1

For information it's possible with powershell

With this you can choose permission you want and if you want only add you can do this like this:

Add-PSSnapin "Microsoft.SharePoint.PowerShell" -ErrorAction SilentlyContinue
$url="http://mysp"
$web=get-spweb $url


#check permission level doesn't exist
if($web.RoleDefinitions["AddOnly"] -eq $null){

    $spRoleDefinition = New-Object Microsoft.SharePoint.SPRoleDefinition    
    $spRoleDefinition.Name = "AddOnly"    
    $spRoleDefinition.Description = "Can only add"    
    # .Type is a ReadOnly property, hence it'll remain on "None".     
    # Use the command [System.Enum]::GetNames    ("Microsoft.SharePoint.SPBasePermissions") to get a list of possible BasePermission values    
    # For this Permission Level, we'll add only add permissions:    
    $spRoleDefinition.BasePermissions = "AddListItems"
    #ViewListItems, AddListItems, EditListItems, OpenItems, ViewVersions, Open, ViewPages, EditMyUserInfo, ManagePersonalViews"    
    $web.RoleDefinitions.Add($spRoleDefinition)

}else{
    $PermissionLevel = "AddOnly"
    $BasePermission = "AddListItems"
    $spRoleDefinition = $web.RoleDefinitions[$PermissionLevel]
    $spRoleDefinition.BasePermissions = $BasePermission
    $spRoleDefinition.Update()

}

0

Out of the box I don't think there is anything you can do to achieve this. However, if you have access to SharePoint designer you can create a workflow to move submitted documents out into a separate document library with restricted permissions.

0

You can add a filter to the view. Filter it down to the user who created the file.

Reference:- How can I allow users to add documents to a library but not be able to open other documents listed?

1
  • This will prevent the user from seeing the document but it doesn't provide real security as they still have permission to open the files. Although if the data isn't sensitive this is probably a nice and quick solution.
    – uint32
    Jul 7, 2014 at 9:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.