Home > SharePoint 2013 > How to fix “’Activate Features’: System.NullReferenceException: Object reference not set to an instance of an object.” when deploying SharePoint2013 workflow

How to fix “’Activate Features’: System.NullReferenceException: Object reference not set to an instance of an object.” when deploying SharePoint2013 workflow

Problem:

I encounter the following error when trying to deploy the SharePoint2013 workflow using visual studio 2012 and the error message itself does not really explain why it happened.

Analysis:

After I put some time to think why this could happen, I figure out it is because you either do not configure your windows Azure workflow or forgot to register your site collection with window azure workflow.

Solution:

To configure the workflow you need to check this MSDN article How to: Set up and configure SharePoint 2013 workflows

To check your site collection is registered properly with window azure workflow. Run the following PowerShell command

If it returns true, the configuration is good

Otherwise you need to run the following to configure register your site. You need to adjust your url in the following script for your environment.


Register-SPWorkflowService –SPSite "http://sp2013" –WorkflowHostUri "http://localhost:12291" –AllowOAuthHttp

References:

Start: Set up and configure SharePoint 2013 Workflow Manager

Advertisements
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: