Thursday, July 18, 2013

SharePoint Designer Workflow Actions using elevated permissions

Workflow Issues in Permission.

After the completion of workflow, form is not getting copied to destination forms library. If the user who initiated the workflow is having access to the destination forms library, form is getting moved over but for other users workflow is showing error in Sps2010.

Some of us might have encountered a situation where we need to copy or move a document (usually InfoPath form) once it is uploaded/submitted by the user to a different library where the user doesn’t have permission. With SharePoint 2007, we used an open source extension to achieve this functionality. With the extension, we were able to copy/move the document from one library to another using the System account privileges. Using the system account privilege in a workflow action of course has its own security issues.
Now, SharePoint 2010 workflow (SharePoint Designer 2010) is out of this hassle. SharePoint Designer 2010 workflow has a new feature called “Impersonation Step”. This is nothing but a workflow step by any actions included in this step will be executed using the Workflow author’s privilege instead of the user who is submitting the document. The Impersonation Step is present in the Insert section of SharePoint Designer ribbon.
Tip:
SharePoint Designer always use the logged in user’s (workflow author) credentials for running the impersonation step. If you are unable to log in to the local computer using the account you want to use for impersonation step, you can run SharePoint designer as a different user using the following method.
  1. Navigate to the folder C:\Program Files (x86)\Microsoft Office\Office14\
  2. Right click the file SPDESIGN.EXE and select ‘Run as different user’ context menu item (you can also create a shortcut to this file on Desktop and right click the shortcut).
  3. Enter the network credentials (or different user account) you prefer to run SPD as.

No comments:

Post a Comment