Working with sub-workflow in rehosted designer?

房东的猫 提交于 2019-12-23 01:49:12

问题


Is it possible to work with a sub-workflow (i.e. subset of the workflow in the designer). For example a sequence, a flowchart, or any activity inside the workflow.

My idea is something like these:

  • Save the subworkflow to a file (for example, save the selected Sequence activity)
  • Load a saved subworkflow and add it into current workflow
  • Add a sub-workflow as an item in toolbox

Are these even possible in WF4?


回答1:


Sounds very much like your sub worklfows are just composite activities. Doing so is easy if you compile them as they become regular activity types and you can do with them as you like. If you don't want to compile them but use them as XAML files you will need to create a compiled wrapper activity using a DynamicActivity and the ActivityXamlServices. This is needed because activities added to a workflow or shown in the toolbox are always compiled.



来源:https://stackoverflow.com/questions/4263715/working-with-sub-workflow-in-rehosted-designer

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!