Skip to content

Writing Your Own SharePoint Publishing Approval Workflow

Out of the box SharePoint has a Publishing Approval workflow that’s hooked up to libraries to support approval of published content. It’s possible to modify this workflow to support your own needs – but there may be some times when you want to author a new workflow from scratch. This works fine in SPD, except that once created you can’t associate it so that it is started when someone tries to publish a new major version of the item. Take a look at the following two screen shots:

If you want to enable this option you’ll need to directly edit the workflow’s configuration XML files. To do this go to the All Files option

Help Your SharePoint User

Then go to _catalogs then wfpub and the name of your workflow. Note that there’s a different location for non-globally published workflows but since you want this to work anywhere in the site collection you’ll want to work with a globally published workflow. Once you have your folder you should see something like:

Right click the .wfconfig.xml file, select open with, and SharePoint Designer (Open as XML)

In the file add AllowStartOnMajorCheckin=”true”

If you created the workflow on a content type you may need to remove the Category and ContentTypeID attributes of the Template node to allow the workflow to be associated with the library. The Start this workflow to approve publishing a major version of an item is only available on the library – this start option isn’t available for a content type.

5 Comments

  1. Thank you, I was wondering why the option was missing, and how to get it back. Didn’t want to resolve to manual starting, and didn’t want to bother the approvers before check-in using those auto-start options.

  2. great post.
    Just for info of others who read this and wonder where to place this tag:

    You need to place this in

  3. Great post Robert. This is exactly what I would like to do as it makes no sense to start the approval process if the document editor hasn’t checked the file in. I followed your instructions but the workflow does not start when a file in my library has been checked in. Is there something else I need to do? Thanks,
    Steve

  4. Thanks, worked perfectly.

  5. For sharepoint 2013 custom designer workflows,This option is always disabled and not able to find XOMl file lcoation to update it.Any idea how to enable this option for sharepoint2013 designer workflows


Add a Comment

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Share this: