Search code examples
c#.networkflow-foundationbusiness-logicworkflow-activity

How do I softcode a workflow activity in .NET?


I need to write a static method which is performing some kind of parsing on a string with signature like:

string ParseMessage(string messageToParse)

I would like the whole method ParseMessage to be soft-coded, i.e. not precompiled within the main output of the project, which is a common windows forms application. How do I do this using a workflow activity?

I would like to:

  1. Create an activity defined in a xaml file
  2. Load the activity into my windows forms application
  3. Run the activity by passing the arguments (a variable of string type)
  4. Get the result in a variable of string type

Solution

  • There is a very interesting tutorial from Channel9, going directly to the point:

    http://channel9.msdn.com/Learn/Courses/VS2010/WCFWF/IntroToWF/Exercise-5-Testing-Workflows