none
is this possible? RRS feed

  • Question

  • Hi everybody

    I'm no a SharePoint developer and therefor I don't know what is possible to develop and what is not.

    Now my question:
    We have a list in SharePoint. One user creates all entries in this list. There is a column in the list to assign an entry to a specific user. What we like to achieve is, that as soon as an entry is assigned to an user, the item level permission is automatically changed so that only the creator an the assigned user can see the entry.

    I know that this is possible with a workflow. But then we would have to adjust the workflow for every new user. And we would like to have something dynamically.

    My question is just if this is possible or not and how this could be done. With how I mean could this be an add in or something else. I don't need to know the details.

    Thanks for the help.

    Friday, December 16, 2016 1:52 PM

Answers

  • You need to work with variables ...

    You can achieve this with some basic get and set functions from your workflow.

    See links bellow for examples on how to get/set Workflow variables :

    http://www.nothingbutsharepoint.com/2012/01/18/how-to-retrieve-users-manager-in-sharepoint-designer-workflows-aspx/

    https://blogs.msdn.microsoft.com/workflows_for_product_catalogs/2012/11/02/create-a-simple-workflow-in-sharepoint-designer-that-reads-from-and-writes-to-the-products-list-in-sharepoint-2013/


    JH

    • Marked as answer by Udeo Thursday, December 22, 2016 2:20 PM
    Monday, December 19, 2016 7:44 AM

All replies

  • Yes it is possible and yes you can do it with a workflow.  I've also done this in the past with an Event Receiver (if you are on-premises and can use server side code).  Assuming the assignment column is of type User/Group you should be able to pick up the user from there, which wouldn't require modifying the workflow for new users.  It will need to be a 2010 Workflow however since 2013 workflow doesn't contain an action for changing item level permissions.

    Paul Stork SharePoint Server MVP
    Principal Architect: Blue Chip Consulting Group
    Blog: http://dontpapanic.com/blog
    Twitter: Follow @pstork
    Please remember to mark your question as "answered" if this solves your problem.

    Friday, December 16, 2016 2:03 PM
  • Hi Paul

    Thanks for the fast answer. Unfortunately in this case the list is on SharePoint online.

    Friday, December 16, 2016 2:14 PM
  • Hi Udeo,

    You can create SharePoint 2010 Workflows under a SharePoint 2013 Online site.

    If you are using SharePoint Designer to do that, when prompted to fill in the name and description of your Workflow, you can specify the platform type and set it to "SharePoint 2010 Workflow" on the drop down list.

    As Paul said, SharePoint 2010 Workflows can be handy for such operations.

    You can also create your SharePoint 2013 Workflow and call for a SharePoint 2010 workflow action just for the permissions editing step.


    JH

    Friday, December 16, 2016 2:51 PM
  • That just means you have to do it as a workflow and not as an event receiver.  2010 style workflows are available in SharePoint Online.

    Paul Stork SharePoint Server MVP
    Principal Architect: Blue Chip Consulting Group
    Blog: http://dontpapanic.com/blog
    Twitter: Follow @pstork
    Please remember to mark your question as "answered" if this solves your problem.

    Friday, December 16, 2016 8:07 PM
  • When I create a 2010 workflow, I can select the condition when my user/group field is changed. That's one thing. But the other thing is the action. As far as I see it, for the action I can only set the change of permission to a specific user and not to the user I entered in the user/group field.

    Maybe I do something wrong?

    Monday, December 19, 2016 6:23 AM
  • You need to work with variables ...

    You can achieve this with some basic get and set functions from your workflow.

    See links bellow for examples on how to get/set Workflow variables :

    http://www.nothingbutsharepoint.com/2012/01/18/how-to-retrieve-users-manager-in-sharepoint-designer-workflows-aspx/

    https://blogs.msdn.microsoft.com/workflows_for_product_catalogs/2012/11/02/create-a-simple-workflow-in-sharepoint-designer-that-reads-from-and-writes-to-the-products-list-in-sharepoint-2013/


    JH

    • Marked as answer by Udeo Thursday, December 22, 2016 2:20 PM
    Monday, December 19, 2016 7:44 AM
  • With the information in the provided links I could configure a workflow that does what I tried to achieve.

    Thanks!

    Thursday, December 22, 2016 2:21 PM