<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>State Machine Workflow on Matt Thornton</title>
    <link>http://localhost:1313/tags/state-machine-workflow/</link>
    <description>Recent content in State Machine Workflow on Matt Thornton</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>en</language>
    <lastBuildDate>Wed, 03 Oct 2012 12:59:06 +0000</lastBuildDate><atom:link href="http://localhost:1313/tags/state-machine-workflow/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>SharePoint 2010 State Machine workflow delayActivity tip</title>
      <link>http://localhost:1313/tech/sharepoint/sharepoint-2010-state-machine-workflow-delayactivity-tip/</link>
      <pubDate>Wed, 03 Oct 2012 12:59:06 +0000</pubDate>
      
      <guid>http://localhost:1313/tech/sharepoint/sharepoint-2010-state-machine-workflow-delayactivity-tip/</guid>
      
        <description>&lt;p&gt;If you&amp;rsquo;re using a delayActivity in your Visual Studio State Machine workflow, you are likely to want to use the InitializeTimeoutDuration handler to set the length of the delay.&lt;/p&gt;
&lt;p&gt;An easy mistake to make is to think you could do the following:&lt;/p&gt;
&lt;pre&gt;private void DelayActivity_InitializeTimeoutDuration(object sender, EventArgs e)
        {
            delayActivity1.TimeoutDuration = new TimeSpan(0, 10, 0);
        }
&lt;/pre&gt;
&lt;p&gt;However, this won&amp;rsquo;t work. This is because SharePoint will intialise a new instance of the delayActivity with the timeoutduration specified as default. To set the TimeoutDuration of your “actual” activity, you should do the following:&lt;/p&gt;</description>
      
    </item>
    
    <item>
      <title>Activity onWorkflowItemChanged validation warning: The correlation token may be uninitialized</title>
      <link>http://localhost:1313/tech/sharepoint/activity-onworkflowitemchanged-validation-warning-the-correlation-token-may-be-uninitialized/</link>
      <pubDate>Sun, 23 Sep 2012 13:45:34 +0000</pubDate>
      
      <guid>http://localhost:1313/tech/sharepoint/activity-onworkflowitemchanged-validation-warning-the-correlation-token-may-be-uninitialized/</guid>
      
        <description>&lt;p&gt;&lt;em&gt;&lt;strong&gt;Update:&lt;/strong&gt; the below information is useful reference, but you may find it leads to undesirable results, where your workflowItem events fire repeatedly. Read the below, and then read &lt;a href=&#34;https://www.matt-thornton.net/tech/sharepoint/sharepoint-2010-state-machine-workflow-onworkflowitemchanged-firing-multiple-times&#34;&gt;this&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;Working in Visual Studio 2010 and designing SharePoint 2010 state machine and sequential workflows, you may come across the following warning message when building and deploying your solution when using the onWorkflowItemChanged event:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Activity ‘onWorkflowItemChanged&amp;rsquo; validation warning: The correlation token may be uninitialized&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;You will also probably notice that your workflow doesn&amp;rsquo;t respond or wake up to any onWorkflowItemChanged events. This is almost certainly due to the correlation token you&amp;rsquo;re using. The way to get this working correctly is:&lt;/p&gt;</description>
      
    </item>
    
  </channel>
</rss>