Saturday, September 11, 2010
FlowChart is new type in WorkFlow. it is used to eaily mantains Large Applications.Old version of Workflow , the WorkflowRuntime was restricted to one WorkflowRuntime. Now WorkFlowInstance has been replaced with the class WorkflowInstance.Now you can easily attached Event Handler and delegate to each workflow becasue of Class WorkflowInstance.
Open your Visual Studio 2010. Create new workflow console application from visual studio Menu New->Project.
From Solution Explorer double click on Workflow1.xaml file.
Drag and drop a Flowchart activity from Flowchart group onto the desginer surface as shown in Figure 1.1
The green circle indicates where the workflow starts.
Drag and drop WriteLine activity to surface area from Primitives group as shown in Figure 1.2
Take your mouse pointer to green circle, three gray dot will be appear, drag a node to writeline activity and drop it on one gray node. You will see the direction of workflow from circle to writeline as shown in Figure 1.3
Goto the properties of Writeline activity and Click the linkbutton of text. Small window will be open write the VB expression as shown in below Figure 1.4
Open your Program.cs file and add
Console.Write("Press enter to exit.");
Console.ReadKey() will prevent to immedialtely close of window.
Press F5 to run it.
Figure 1.5 shows the output.
Part 1 - Workflow Console Application