Windows workflow: starting a separate workflow from a workflow

This seems more complicated than I previously suspected. I have a workflow that should run another workflow in code. How it's done? Should I get a link to the current WorkflowRuntime workflow first?

+3
source share
2 answers

I think InvokeWorkflowActivity may be what you are looking for. I used it to start workflows from other workflows and it works well.

Just remember that new workflows (like all workflows) run asynchronously, so the “parent workflow” will continue to run immediately after the child workflow starts.

If you (for some reason) cannot use InvokeWorkflowActivity (for example, if a new workflow must be started from code in a service called from the parent workflow), you will somehow get a storage instance of the workflow environment.

, , - , , ​​ . , ( ), ; .

+7

Source: https://habr.com/ru/post/1710200/


All Articles