If somebody like the post and its helpful in your work then, add comments.

Thursday, July 21, 2011

SharePoint 2010 : Import List workflow in your custom solution

When you have to import the workflow in your solution, like for Sandbox solution. So, how you will be importing that list workflow in the VS 2010 sandbox solution. Many of us find like import reusable workflow in the VS 2010 solution. But what about the list workflows. And suppose if their is more then one workflow. I have also search lot on this topic and does not get not much help.

Solution Smile!!!!!!!!!!!!!!

To import List workflow on the VS solution. Create a WSP of the Site and import using the VS template  for SharePoint. Now Copy the ListInstances(On which list workflow are created),Modules of the workflow and WorkflowAssociations folders in our custom solution. Now build the solution. It will give some errors of workflow. So over come the errors add reference of following references

  • microsoft.sharepoint.WorkflowActions
  • System.Workflow.Activities
  • System.Workflow.Runtime

It will resolve the some of the errors. Now it will be giving the XOML errors. So to overcome these errors,you have add the same line of the tag from “importsolution.csproj” file to “customsolution.csproj”. Make it similar as import solution.

The changes should be done for workflow.xoml, workflow.xoml.wfconfig.xml and workflow.xoml.rules for all the workflow which are associated with all the list in the WSP. Now all the error will resolved. Deploy the solution and test. The workflow will work fine.

It will help in creation and deployment for the sandbox and SPD workflow. Comment if any help needed.


  1. Useful information, many thanks to the author. It is puzzling to me now, but in general, the usefulness and significance is overwhelming. Very much thanks again and best of luck!

    Sharepoint Staffing

  2. Acetech has many years of experience in custom software development. Find out more about custom software development at http://www.acetechindia.com