O'Reilly logo

Microsoft Windows Workflow Foundation 4.0 Cookbook by Andrew Zhu

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Using RemoveFromCollection<T> activity

In this task, we will use the RemoveFromCollection<T> activity to remove an item from a collection object.

Getting ready

We need to make sure we have finished the task of Printing collection items for us to be able to use the CollectionPrinterActivity in this task.

How to do it...

  1. Create a Console Workflow Application:

    Create a new Workflow Console Application, and name it UsingRemoveFromCollectionActivity.

  2. Create a workflow:

    We need to perform the following tasks to create a workflow:

    1. Open Workflow1.xaml, which is the workflow created by default. Click the Imports button and type in System.Collections.ObjectModel to import the System.Collections.ObjectModel namespace to this workflow.
    2. Drag a Sequence activity ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required