Book Image

Programming Windows Workflow Foundation: Practical WF Techniques and Examples using XAML and C#

By : Kenneth Scott Allen
Book Image

Programming Windows Workflow Foundation: Practical WF Techniques and Examples using XAML and C#

By: Kenneth Scott Allen

Overview of this book

Windows Workflow Foundation (WF) is a technology for defining, executing, and managing workflows. It is part of the .NET Framework 3.0 and will be available natively in the Windows Vista operating system. Windows Workflow Foundation might be the most significant piece of middleware to arrive on the Windows platform since COM+ and the Distributed Transaction Coordinator. The difference is, not every application needs a distributed transaction, but nearly every application does have a workflow encoded inside it. In this book, K Scott Allen, author of renowned .NET articles at www.odetocode.com, provides you with all the information needed to develop successful products with Windows Workflow. From the basics of how Windows Workflow can solve the difficult problems inherent in workflow solutions, through authoring workflows in code, learning about the base activity library in Windows Workflow and the different types of workflow provided, and on to building event-driven workflows using state machines, workflow communications, and finally rules and conditions in Windows Workflow, this book will give you the in-depth information you need. Throughout the book, an example "bug reporting" workflow system is developed, showcasing the technology and techniques used.
Table of Contents (14 chapters)
Programming Windows Workflow Foundation: Practical WF Techniques and Examples using XAML and C#
Credits
About the Author
About the Reviewer
Preface

Pure Code


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.

Pure Code and Visual Studio

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...