MS WF state machine workflows and MS CRM Dynamics

2019-02-22 02:20发布

问题:

MS CRM Dynamics 4.0 incorporates the MS WF engine. The built in designer allows the creation of sequential workflows whos activities have native access to CRM entities.

Is it possible to:

  • Create a state machine workflow outside of CRM (i.e. in visual studio) and import it into CRM?
  • Have this workflow access the CRM entities?

回答1:

  • It is NOT possible to create a state machine workflow for use in MSCRM.
  • It is also not supported to create any workflow outside of MSCRM and import it.
  • As a work around you could write either all the logic you need into a custom workflow activity and import that into MSCRM and have it called from a normal workflow.
  • The other option is build a seperate application which runs a state machine workflow and interacts with MSCRM via the web services. You could (would need to?) combine this with a custom workflow activity to kick off processes.


回答2:

It is possible to create no code workflow...

http://blogs.msdn.com/jonasd/archive/2008/01/21/Creating-a-no_2D00_code-workflow-for-CRM-4.0-with-Visual-Studio-2005-_2800_2008_2900_.aspx

and take a look at the other thread...

Is is possible/a good idea to edit workflows in Visual Studio?



回答3:

I don't know the answer to your specific question, but hopefully this information will point you in the right direction.

The "native" format for WF workflows is ".xoml" files. These are basically identical to XAML files, and both are nothing more than generic persistence formats for a .NET object tree. If you can access the saved data that is output by the Dynamics designer, it should be in the same format. If it is, you should be able to open it from the Visual Studio designer.

The key here is that CRM undoubtedly defines its own set of custom activities that you'll need to be able to reference from within the alternate designer. With any luck, these will be in assemblies with obvious names and/or in the GAC.