Skip to Content
Microsoft Windows Workflow Foundation 4.0 Cookbook
book

Microsoft Windows Workflow Foundation 4.0 Cookbook

by Andrew Zhu
September 2010
Intermediate to advanced content levelIntermediate to advanced
272 pages
5h 16m
English
Packt Publishing
Content preview from Microsoft Windows Workflow Foundation 4.0 Cookbook

Hosting workflow in a Windows Form

In this task we will create a workflow running in a Windows Form application.

How to do it...

  1. Create a Windows Form project:

    Create a Windows Form project and name it HostingWorkflowInWinForm.

  2. Create a workflow:

    Add a workflow to the project and call it AdditionWorkflow.xaml. Author the workflow like this:

    How to do it...
  3. Create a Windows Form.

    Open the default created Form1.cs file and alter it to:

    How to do it...

    Double-click the Adding button and add code to the button event handler. The final code will be:

    using System;using System.Windows.Forms;using ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Essential Windows Workflow Foundation

Essential Windows Workflow Foundation

Dharma Shukla, Bob Schmidt

Publisher Resources

ISBN: 9781849680783Other