This SharePoint workflow tutorial explains, how we can attach a workflow to a content type in SharePoint 2010.
A SharePoint workflow can be attached to a list, site or to a content type in SharePoint 2010. But there are only two options in the workflow wizard: list or site workflow. So how do you associate the workflow with a content type? In order to associate the workflow with a content type, you have to change the AssociationCategories element value in the workflow’s Elements.xml file to ContentType.
For this Double-click the Elements.xml file for the workflow to open it.
Locate the AssociationCategories element and change its value to ContentType like:
Click on the Workflow1 project item folder and open the Properties window. And change the value of the Auto Associate property from True to False.
Then press F5 to build, package and deploy the project.
Then go to the Site Actions ->Site Settings and under document content types click the Document content type.
You may like following SharePoint workflow tutorials:
- Create SharePoint Site Collection and Site using Nintex Workflow for Office 365
- Step by Step Nintex Workflow tutorial for Office 365 SharePoint Online
- Deploy sharepoint 2013 designer workflow into production in SharePoint online
- Create Workflow Activity using Visual Studio 2010 in SharePoint 2010
- Create approval workflow sharepoint 2010 using SharePoint designer
- Steps to create a list workflow using SharePoint 2010 designer
- Change Item Level Permission using SharePoint designer workflow
- App Step in SharePoint 2013 Designer Workflow
- Three State Workflow in SharePoint with Example
Now click the workflow settings link, the Workflow settings page is displayed. Click the Add a workflow link, the add a workflow page will be displayed and from there you can select the workflow for the content type.
I am Bijay from Odisha, India. Currently working in my own venture TSInfo Technologies in Bangalore, India. I am Microsoft Office Servers and Services (SharePoint) MVP (5 times). I works in SharePoint 2016/2013/2010, SharePoint Online Office 365 etc. Check out My MVP Profile.. I also run popular SharePoint web site SPGuides.com
Download SharePoint Online Tutorial PDF FREE!
Get update on Webinars, video tutorials, training courses etc.