Building a workflow with a pure code approach means we are only using C# or Visual Basic code to define the workflow. There is no XAML involved. This doesn't mean we have to write all the code ourselves. Many designers in Visual Studio, like the Windows forms designer, have been generating C# and Visual Basic code for years. The workflow designer has the ability to generate code for us. We will want to combine the designer-generated code with our own code to build a workflow.
The Visual Studio 2005 Extensions for Windows Workflow package will add project and item templates into Visual Studio. These item templates provide a starting point for building a workflow project, a workflow, or an activity.
To use an item template we merely need to right-click a project and select Add | New Item. One of the item templates appearing in the Add New Item dialog box sets up the files and code needed to support a pure code approach. This item template is the Sequential...