Click here to Skip to main content
15,881,173 members
Articles / Programming Languages / C#

WF 4 Persistence, Tracking, and Bookmarks: A Practical Approach

Rate me:
Please Sign up or sign in to vote.
4.73/5 (31 votes)
21 Aug 2010CPOL17 min read 141.8K   8.5K   62  
Shows practical examples about WF 4 Persistence, Tracking, and Bookmarks.
<Activity mc:Ignorable="sap" x:Class="OrderProcess.Workflow1" sap:VirtualizedContainerService.HintSize="880,676" mva:VisualBasic.Settings="Assembly references and imported namespaces for internal implementation" xmlns="http://schemas.microsoft.com/netfx/2009/xaml/activities" xmlns:av="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:local="clr-namespace:OrderProcess" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:mv="clr-namespace:Microsoft.VisualBasic;assembly=System" xmlns:mva="clr-namespace:Microsoft.VisualBasic.Activities;assembly=System.Activities" xmlns:s="clr-namespace:System;assembly=mscorlib" xmlns:s1="clr-namespace:System;assembly=System" xmlns:s2="clr-namespace:System;assembly=System.Xml" xmlns:s3="clr-namespace:System;assembly=System.Core" xmlns:s4="clr-namespace:System;assembly=System.ServiceModel" xmlns:sa="clr-namespace:System.Activities;assembly=System.Activities" xmlns:sad="clr-namespace:System.Activities.Debugger;assembly=System.Activities" xmlns:sap="http://schemas.microsoft.com/netfx/2009/xaml/activities/presentation" xmlns:scg="clr-namespace:System.Collections.Generic;assembly=System" xmlns:scg1="clr-namespace:System.Collections.Generic;assembly=System.ServiceModel" xmlns:scg2="clr-namespace:System.Collections.Generic;assembly=System.Core" xmlns:scg3="clr-namespace:System.Collections.Generic;assembly=mscorlib" xmlns:sd="clr-namespace:System.Data;assembly=System.Data" xmlns:sl="clr-namespace:System.Linq;assembly=System.Core" xmlns:st="clr-namespace:System.Threading;assembly=System.Core" xmlns:st1="clr-namespace:System.Threading;assembly=System" xmlns:st2="clr-namespace:System.Text;assembly=mscorlib" xmlns:st3="clr-namespace:System.Threading;assembly=mscorlib" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
  <Flowchart sad:XamlDebuggerXmlReader.FileName="C:\Users\Mohamad\Desktop\OrderProcess\OrderProcess\Workflow1.xaml" sap:VirtualizedContainerService.HintSize="840,636">
    <sap:WorkflowViewStateService.ViewState>
      <scg3:Dictionary x:TypeArguments="x:String, x:Object">
        <x:Boolean x:Key="IsExpanded">False</x:Boolean>
        <av:Point x:Key="ShapeLocation">270,2.5</av:Point>
        <av:Size x:Key="ShapeSize">60,75</av:Size>
        <av:PointCollection x:Key="ConnectorLocation">330,40 360,40 360,50 394.5,50</av:PointCollection>
        <x:Double x:Key="Width">826.5</x:Double>
      </scg3:Dictionary>
    </sap:WorkflowViewStateService.ViewState>
    <Flowchart.StartNode>
      <FlowStep x:Name="__ReferenceID2">
        <sap:WorkflowViewStateService.ViewState>
          <scg3:Dictionary x:TypeArguments="x:String, x:Object">
            <av:Point x:Key="ShapeLocation">394.5,20.5</av:Point>
            <av:Size x:Key="ShapeSize">211,61</av:Size>
            <av:PointCollection x:Key="ConnectorLocation">500,81.5 500,111.5 280,111.5 280,129.5</av:PointCollection>
          </scg3:Dictionary>
        </sap:WorkflowViewStateService.ViewState>
        <WriteLine sap:VirtualizedContainerService.HintSize="211,61" Text="[&quot;WF thread: &quot; + System.Threading.Thread.CurrentThread.ManagedThreadId.ToString()]" />
        <FlowStep.Next>
          <FlowStep x:Name="__ReferenceID0">
            <sap:WorkflowViewStateService.ViewState>
              <scg3:Dictionary x:TypeArguments="x:String, x:Object">
                <av:Point x:Key="ShapeLocation">174.5,129.5</av:Point>
                <av:Size x:Key="ShapeSize">211,61</av:Size>
                <av:PointCollection x:Key="ConnectorLocation">280,190.5 260,190.5 260,219</av:PointCollection>
              </scg3:Dictionary>
            </sap:WorkflowViewStateService.ViewState>
            <WriteLine sap:VirtualizedContainerService.HintSize="211,61" Text="Enter product name" />
            <FlowStep.Next>
              <FlowStep x:Name="__ReferenceID4">
                <sap:WorkflowViewStateService.ViewState>
                  <scg3:Dictionary x:TypeArguments="x:String, x:Object">
                    <av:Point x:Key="ShapeLocation">160,219</av:Point>
                    <av:Size x:Key="ShapeSize">200,22</av:Size>
                    <av:PointCollection x:Key="ConnectorLocation">260,241 250,241 250,269.5</av:PointCollection>
                  </scg3:Dictionary>
                </sap:WorkflowViewStateService.ViewState>
                <local:SubmitOrderName sap:VirtualizedContainerService.HintSize="200,22" />
                <FlowStep.Next>
                  <FlowStep x:Name="__ReferenceID3">
                    <sap:WorkflowViewStateService.ViewState>
                      <scg3:Dictionary x:TypeArguments="x:String, x:Object">
                        <av:Point x:Key="ShapeLocation">144.5,269.5</av:Point>
                        <av:Size x:Key="ShapeSize">211,61</av:Size>
                        <av:PointCollection x:Key="ConnectorLocation">250,330.5 250,360.5 290,360.5 290,379.5</av:PointCollection>
                      </scg3:Dictionary>
                    </sap:WorkflowViewStateService.ViewState>
                    <WriteLine sap:VirtualizedContainerService.HintSize="211,61" Text="[&quot;WF thread: &quot; + System.Threading.Thread.CurrentThread.ManagedThreadId.ToString()]" />
                    <FlowStep.Next>
                      <FlowStep x:Name="__ReferenceID1">
                        <sap:WorkflowViewStateService.ViewState>
                          <scg3:Dictionary x:TypeArguments="x:String, x:Object">
                            <av:Point x:Key="ShapeLocation">184.5,379.5</av:Point>
                            <av:Size x:Key="ShapeSize">211,61</av:Size>
                          </scg3:Dictionary>
                        </sap:WorkflowViewStateService.ViewState>
                        <WriteLine sap:VirtualizedContainerService.HintSize="211,61" Text="Workflow Ended" />
                      </FlowStep>
                    </FlowStep.Next>
                  </FlowStep>
                </FlowStep.Next>
              </FlowStep>
            </FlowStep.Next>
          </FlowStep>
        </FlowStep.Next>
      </FlowStep>
    </Flowchart.StartNode>
    <x:Reference>__ReferenceID0</x:Reference>
    <x:Reference>__ReferenceID1</x:Reference>
    <x:Reference>__ReferenceID2</x:Reference>
    <x:Reference>__ReferenceID3</x:Reference>
    <x:Reference>__ReferenceID4</x:Reference>
  </Flowchart>
</Activity>

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Architect
Lebanon Lebanon

Comments and Discussions