NullReferenceException when using a custom WorkflowTask derived content type

If you are encountering an “Unknown Error” or exception when calling Update() on a task item using a custom content type derived from WorkflowTask, of type NullReferenceException; then it’s worth checking that your ContentType definition includes the FieldRefs tag, even if it will be a self closing tag.

I encountered this problem recently, and it manifested itself when calling Update() on the list item from the custom Edit form.

Advertisements

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: