共用方式為


Be careful! Duplicate Correlation Tokens!

This is a nice one,

One of the bad things of copying and pasting in Visual Studio (Workflow extensions :) ), is missing up  your correlation tokens

look at this:

image

where in code (workflow1.designer.cs) you find this:

correlationtoken4.Name = "workflowtoken";

correlationtoken2.Name = "workflowtoken";

 

This will compile fine, your workflow might not work.

specially if you have a set of activities that all relate to each other,

deal with the token to be your sort of a session thing or a scope that your workflow activities live together in that token.

image

all of these activities are related with one Token and be careful they are not duplicate. it might have the same token name but not the same token.

Comments

  • Anonymous
    April 07, 2008
    The comment has been removed
  • Anonymous
    April 24, 2008
    Dear Dave, what you need to do is that make sure that you don't have duplicate tokens, there is no problem in modifying the designer.cs code at all but just be careful while do it,, :)