Skip to main content

Workflow (Design & Run WF Activities)

  • 4 minutes to read

The Workflow module integrates Windows Workflow Foundation (WF) 4.0/4.5 support into XAF. WF is a workflow management framework designed to assist you in creating more manageable, workflow-enabled applications. Leveraging the WF functionality, the Workflow module is designed specifically for the following kinds of WinForms and ASP.NET Web Forms applications.

  • Applications automating long-running business processes with intermediate steps being hours, days or weeks apart.
  • Applications allowing users to modify the automated business processes without writing any code.
  • Applications visualizing complex business processes.

Generally, such applications are built around a business process definition that is a series of steps describing software activities and actions of involved users. Typically, this process is long-running, and the application must wait, for instance, for several days to receive input from a particular user. An example of such an application can be a bug tracker that relies on users to report issues, research and fix them. The bug tracker can be built around a complex long-running process, which can evolve based on user feedback. Without WF, developing and supporting an application with such requirements is a serious task and is not easily done. The Workflow module integrates WF support into XAF and simplifies design and execution of workflows. With the Workflow module, you only need to know the general concepts associated with workflow design.

The Windows Workflow Foundation (WWF) framework from Microsoft is a broad and complex product. To use the Workflow Module effectively, you should be familiar with WF and WCF technologies and understand how client-server apps are built and communicate.

Note

  • WWF and WCF will not be ported to .NET Core/.NET 6+ by Microsoft. We recommend that you implement Controllers or custom solutions such as Hangfire, Quartz.NET, and others for former Workflow Module scenarios. To save time, consider this free module within the eXpand Framework.
  • The Windows Workflow Foundation feature is not included in Visual Studio ASP.NET and web development and .NET desktop development workloads. You should enable this feature in Visual Studio Installer’s Individual Component tab.

Our integration with WF includes the implementation of custom workflow instance stores, whose correct operation depends on the quality and amount of WF documentation and other public information on the subject. We do not recommend using our Workflow module if your project specifics or other business requirements do not allow you to investigate possible problems that may emerge (due to WF or our integration specifics) in a short period OR if these problems cannot be reproduced in another environment.

XAF uses the WorkflowService class to start activity instances so you can design any activity in VisualStudio and use it in an XAF application if it can be passed to the WorkflowService. XAF code doesn’t extend the WWF engine and uses this class to start the designed activities. XAF already includes a number of standard WWF activities in the toolbox in the runtime workflow designer, and you can include additional activities as described in the Add Activities to the Workflow Designer Toolbox topic.

To learn more about the module and how to use it, refer to the following documents.

Concepts

Task-Based Help

Community Content

MSDN Articles

If you have not dealt with WF in the past, take a look at these introductory WF materials describing general workflow concepts and the basics of workflow design.