This section mainly introduces the use of parallel,pick,pickbranch,parallelforeach<t>.
This example downloads:
Http://files.cnblogs.com/foundation/controlActivitySample2.rar
This example illustrates
Control flow Activity
Parallel Parallel container
Class name |
System.Activities.Statements.Parallel |
File |
System.Activities.dll |
Structure description |
Inherit nativeactivity is a sealed class Override [CacheMetadata method] and [Execute method] and [Cancel method] The [Completioncondition] property is of type [activity<bool>] and can accept an expression with a result of [bool] The [branches] property is of type [Collection<activity>] and is a parallel branch collection The [Variables] property is of type [Collection<variable>] |
Function description |
You can define variables in [Parallel] [Parallel] Executes all the activity in the [branches] collection in parallel When the [Completioncondition property] is true, the parallel container completes, and other incomplete execution branches are no longer executed (including half of the execution branch) |