How to: Create a Workflow Console Application
Windows Workflow Foundation (WF) allows you to create workflows for executing system or human processes. The Windows Workflow Designer provides the design surface for creating these workflows. The Workflow Designer can be used to create workflows from within Visual Studio or it can be integrated into other applications that rehost the designer.
This topic describes how to use the Workflow Designer in Visual Studio 2010 to create a workflow in a console application.
To create a workflow console application
Start Visual Studio 2010.
On the File menu, point to New, and then select Project….
The New Project dialog box opens.
In the Installed Templates pane, select Workflow from either the Visual C# or Visual Basic groupings, depending on your language of preference.
In the middle pane, select Workflow Console Application.
In the Name box, enter a descriptive name for your project to make it easy to identify.
In the Location box, enter the directory in which you want to save your project, or click Browse to navigate to it.
In the Solution box, enter the name for the new solution. Click OK to create the application.
If you want to add a workflow console application to an existing solution, open that solution in Visual Studio 2010, right click the solution in Solution Explorer, and select Add, then New Project… to open the New Project dialog box. Proceed as described above in this procedure.
The project template creates a workflow definition in XAML and the console application definition is in source code. The Workflow Designer opens and displays the canvas for the workflow you created.
To compose a workflow, drag activities or other workflow items from the Toolbox to the design surface in your workflow.