Integrating Integrators – BizTalk, Windows Azure, Windows Workflow, and Beyond

December, 2009

Windows Workflow

This is the top level group for Microsoft Windows Workflow Foundation. Find blogs, samples, videos, and learning resources for various versions of workflow including 3.0, 3.5, and 4.0 here.

Windows Workflow Community Blogs via Syndication

Windows Workflow Foundation related bloggers. All content is property of the original blog owner.
  • Windows Workflow Community Blogs via Syndication

    Swiss Cheese and WF4, or, An Introduction to ActivityAction

    One common scenario that was often requested by customers of WF 3 was the ability to have templated or “grey box” or “activities with holes” in them (hence the Swiss cheese photo above).  In WF4 we’ve done this in a way that way we call ActivityAction Motivation First I’d like to do a little bit more to motivate the scenario.  Consider an activity that you have created for your ERP system called CheckInventory.  You’ve gone ahead and encapsulated all of the logic of your inventory...
  • Windows Workflow Community Blogs via Syndication

    Inspection, Default Services and Items (WF4 EditingContext Intro Part 6)

    This part 6 of my 6 part series on the EditingContext. Introduction Sharing Functionality between Designers Host provided capabilities Providing callbacks for the host Subscription/Notification engine Inspection, Default Services and Items (you are here) I want to wrap up this series of posts by posting some code for an activity designer that functions more as a diagnostic tool, and will display all of the Items and services of the EditingContext within the designer. This will be useful from an investigation...
  • Windows Workflow Community Blogs via Syndication

    Subscription / Notification Engine (WF4 EditingContext Intro Part 5)

    This part 5 of my 6  part series on the EditingContext. Introduction Sharing Functionality between Designers   Host provided capabilities    Providing callbacks for the host   Subscription/Notification engine (you are here) Inspection, Default Services and Items In this post, we’re going to tie together a few of the things we’ve seen in the last few posts and show how we can wire up parts of the designer (or the hosting application) to changes made to the Items collection...
  • Windows Workflow Community Blogs via Syndication

    Providing Callbacks for the Host (WF4 EditingContext Intro Part 4)

    This part 4 of my 6  part series on the EditingContext. Introduction Sharing Functionality between Designers  (you are here) Host provided capabilities Providing callbacks for the host Subscription/Notification engine Inspection, Default Services and Items   In addition to having a host provide an instance of a type to be used within the designer, it can also be used to pass an instance that will route callbacks to the host.  I covered this briefly in a previous post ( Displaying...
  • Windows Workflow Community Blogs via Syndication

    Host Provided Capabilities (WF4 EditingContext Intro Part 3)

    This part 3 of my 6  part series on the EditingContext. Introduction Sharing Functionality between Designers   Host provided capabilities  (you are here) Providing callbacks for the host Subscription/Notification engine Inspection, Default Services and Items EditingContext is used by our primary hosting application, Visual Studio, to provide concrete implementations of certain services.  The example that we will talk about here is the IExpressionEditorService .  Now, one...
  • Windows Workflow Community Blogs via Syndication

    Sharing Functionality Between Designers (WF4 EditingContext Intro Part 2)

    This part 2 of my 6 part series on the EditingContext. Introduction Sharing Functionality between Designers  (you are here) Host provided capabilities Providing callbacks for the host Subscription/Notification engine Inspection, Default Services and Items   Setup We will need a custom activity, EmptyOne and designer called InteractWithServiceDesigner.  using System.Activities; using System.ComponentModel; namespace blogEditingContext { [Designer( typeof (InteractWithServicesDesigner...
  • Windows Workflow Community Blogs via Syndication

    Introduction to the WF4 Designer Editing Context (Part 1)

    I want to briefly touch on the editing context and give a little introduction to its capabilities.  This is part 1 of a 6 part series Introduction (you are here) Sharing Functionality between Designers Host provided capabilities Providing callbacks for the host Subscription/Notification engine Inspection, Default Services and Items The way to think about the editing context is that it is the point of contact between the hosting application, and the designer (and elements on the designer). ...
  • Windows Workflow Community Blogs via Syndication

    Emitting the mc:Ignorable Instruction In Your WF4 XAML

    Frequent forum guest Notre posed this question to the forums the other day noting that the XAML being produced from ActivityXamlServices.CreateBuilderWriter() was slightly different than the XAML being output from WorkflowDesigner.Save().   The reason for this stems from the fact that WorkflowDesigner leverages an additional internal type (which derives from XamlXmlWriter) in order to attach the mc:Ignorable attribute.  Why use mc:Ignorable? From the source at MSDN: The mc XML namespace...
  • Windows Workflow Community Blogs via Syndication

    AttachedProperty Part 2, Putting it Together

    On my last post , Jason jumped right to the punchline in his comment here . He asks “if there is an easy way to have the properties value serialized out to the xaml.” First, let’s look at what we need to do from the XAML side. First, create a helper type with a getter and setter for the property that you want to attach.  Here we’re going to attach comments: public class Comment { static AttachableMemberIdentifier CommentTextName = new AttachableMemberIdentifier( typeof (Comment), "CommentText"...
  • Windows Workflow Community Blogs via Syndication

    WF4 Design Time AttachedPropertiesService and Attached Properties

    I’ve been meaning to throw together some thoughts on attached properties and how they can be used within the designer.  Basically, you can think about attached properties as injecting some additional “stuff” onto an instance that you can use elsewhere in your code. Motivation In the designer, we want to be able to have behavior and view tied to interesting aspects of the data.  For instance, we would like to have a view updated when an item becomes selected.  In WPF, we bind the style...
  • Windows Workflow Community Blogs via Syndication

    WF4 ViewStateService

    A comment posted by Notre asked for some more details about view state and attached property services, so I thought I would dive into those next.  I will follow-up in a subsequent post on the AttachedPropertyService, as there is a little bit more going on there. Motivation Why do I care about viewstate?  Well, usually it is because we want to write something down and store it for later that is not required for runtime.  A common example of viewstate is the position of nodes within...
  • Windows Workflow Community Blogs via Syndication

    Where is System.Activities.Design in WF4 Beta2 and Beyond?

    I got an email over the weekend asking about this, and I realized that it’s somewhat buried in this post here .  Anyway, in Beta1, you often saw System.Activities.Design.  For beta2 (and RTM), one important change System.Activities.Design  => System.Activities.Presentation The primary reason for this change is that the *.Design suffix is generally reserved for VS design extensibility.  As our designer ships in the framework, *.Design was not the correct suffix.  *.Presentation...
  • Windows Workflow Community Blogs via Syndication

    VisualWorkflowTrackingWithStepService

    In the last post, we went through the SDK sample where we saw how to use the Designer and the Debugger APIs to understand the workflow execution logic outside of VS in a visual manner. This is certainly one step above the textual tracking records received and making a sense out of it. We will now go one step further. Customers generally ask, Is it possible to have a Re-hosted Debugging as such? Well, not a full blown re-hosted debugger. But some capabilities of it – Certainly. One of the most important...
  • Windows Workflow Community Blogs via Syndication

    VisualWorkflowTracking aka WorkflowSimulator

    In the Beta2 SDK, we shipped a sample called WorkflowSimulator. Essentially, the sample is using the tracking APIs to have a visual understanding of the Workflow execution logic. Thus, as we hit “Run Workflow”, we get the debug kind of adornments on each activity that executed. Let’s actually dwell deeper and understand how we used the Designer and the Debugger APIs to achieve the same. To understand that, let’s take a step back and take a look at the debugging architecture: The most important piece...
  • Windows Workflow Community Blogs via Syndication

    Differentiating between Cut-Copy-Paste/Undo-Redo/Drag-Drop/Move

    A couple of customers have asked this one, as they work with the Programming Model, how do I know if an activity has been drag-dropped vs Copy-Pasted vs an Undo-Redo happened. How do the customers use it? Well, for one of them they wanted to change the name of the activity if it is a Copy-Paste as against a Undo_Redo. For example. In case of a Copy-Pasted activity, the new name should be Sequence2. While for a Undo-Redo, the name should still be Sequence1. The bad news is there is no simple way to...
  • Windows Workflow Community Blogs via Syndication

    ExpressionTextBox – works on Activity properties too!

    So Matt Winkler read my previous post and said hey, what about properties of type Activity<foo>, can’t they be bound to ExpressionTextBoxes too? Snap, I had forgotten about that case. The answer is actually yes, because VisualBasicValue and VisualBasicReference derive from Activity, expressions are then assignable to Activity and then the activity can be scheduled. This is a special case of the property binding. The ExpressionTextBox always generates a VBValue or VBReference and if the returned...
  • Windows Workflow Community Blogs via Syndication

    ExpressionTextBox – for arguments only (well mostly)

    [12/19 edit: ExpressionTextBox is not strictly for arguments only, see the exception here ] In a previous post I alluded to the fact that you should be able to bind an ExpressionTextBox to a CLR property. My hazy memory was that this was done at one point in time by omitting the ArgumentToExpressionConverter from the Expression binding and mucking about with the OwnerActivity and/or PathToArgument properties. So I went ahead and modified my existing sample activity to use a property and changed my...
  • Windows Workflow Community Blogs via Syndication

    Using untyped arguments in an ExpressionTextBox

    The ExpressionTextBox sample code in the SDK works just fine in beta 2. The sample demonstrates the use of an ExpressionTextBox in a custom activity designer. In the sample, I implemented a simple MultiAssign activity, which assigns two values to two variables. In the example, I used untyped InArguments and OutArguments. That particular example was bad for a couple of reasons: If you don’t specify an ExpressionType on an ExpressionTextBox, you get a weird red box around invalid expressions inside...
  • Windows Workflow Community Blogs via Syndication

    I'm a ramblin' wreck from Georgia Tech and a helluva engineer!

    This particular post has nothing to do with technology. I'm an avid college football fan and have always cheered for my alma mater, the Georgia Tech Yellow Jackets. Tonight, for the first time since I have been actively following them, we beat Clemson for the 2nd time this season (39-34) and earned a berth in the BCS Orange Bowl!! Not to downplay Clemson, however, as they put up a really good fight both times and it came down to who had the ball last. The first game was equally amazing to watch...
  • Windows Workflow Community Blogs via Syndication

    Introduction to Windows Workflow 4.0

    Note: I apologize in advance if this first post seems unorganized. There is a lot of material to cover and I couldn’t find a really good way to order the topics. Hang in there and hopefully it will start making sense. In order to help everyone get up to speed with build customization, I wanted to take a few posts to share our collective knowledge on the Workflow framework in .NET 4.0. In this first post I plan to tackle the different base classes that may be used when designing your own custom activities...
Page 1 of 2 (23 items) 12