Thursday, September 18, 2008

Error when you assign workflow to a SharePoint group and its work around

I want to create a simple out of the box “Approval Workflow” and assign it to a SharePoint group. Let’s create approval workflow for “Project Document Library”,

Click “Workflow settings” under “Permissions and Management” menu of document library settings,

Select “Approval” for the workflow template,

I am assigning this workflow to “Workflow Approvers” SharePoint group. As we can see, “Assign a single task to each group entered(Do not expand groups)” checkbox is not selected by default. We will keep this default setting and see what happens,

Click “OK” and add this workflow. Once you add a new document to “Project Document Library” instead of starting workflow it will show you following error,

Also, it will show “Error Occurred” status for Approval Workflow as shown below,

So here is how you can fix this issue. You need to select “Assign a single task to each group entered(Do not expand groups)” checkbox when you assign it to a SharePoint group otherwise it will not start the workflow and result in error.

This will start the approval workflow and update its status accordingly. We can see “In Progress” status and “Approved” status, once the document is approved as shown below,

No comments: