Support of WF 4.5 Designer Improvements in Rehosted Scenarios

As you’ve seen in a previous post, we have added a lot of new features in WF 4.5; see this article for more discussion of those features.  A number of those features (e.g. annotations, auto-surround with sequence, etc.) were developed to improve the authoring experience of workflows.

Many of our customers rehost our designer in their own application/domain-specific authoring environments. Naturally then, these customers have asked which of these new WF4.5 designer capabilities are supported when rehosting the designer.

The new designer features that are supported in the rehosted scenario include: 

  • Outline view of workflow items
  • Designer annotations
  • Multi-select
  • Auto-surround with sequence
  • Pan mode
  • Toolbox search

 The ones that are not supported are: 

  • Find
  • C# Expressions

 Please leave us a comment if you have any questions or comments.

Comments

  • Anonymous
    May 15, 2012
    Hey Hani, If I follow the RehostingWFDesigner example but in VS11 beta, and I am not getting the new features (annotations, etc).  I double checked to make sure I was using the WF4.5 assemblies. Is there additional code that should be added? Thanks for the post!

  • Anonymous
    May 16, 2012
    The RehostingWFDesigner sample that you are referring to is a VS2010/.NET 4 sample. In order to enable the new WF 4.5 designer improvements, you would need to take the following steps:

  1. In the Properties of the DesignerRehosting project, choose ".NET Framework 4.5" as the Target Framework
  2. Enable the feature (e.g. Annotations) that you need in the rehosted designer by modifying the RehostingWFDesigner.xaml.cs file as following:      // create the workflow designer      WorkflowDesigner wd = new WorkflowDesigner();      wd.Context.Services.GetService<DesignerConfigurationService>().AnnotationEnabled = true;      wd.Context.Services.GetService<DesignerConfigurationService>().TargetFrameworkName = new System.Runtime.Versioning.FrameworkName(".NETFramework", new Version(4, 5));      wd.Load(new Sequence());
  • Anonymous
    May 16, 2012
    Hani, Thank you sir...That was the snippit I needed.

  • Anonymous
    June 20, 2012
    What about Intellisense? is that supported?

  • Anonymous
    June 20, 2012
    Intellisense is not supported in the rehosted designer scenario.  Intellisense relies on Visual Studio services (which are not available outside of Visual Studio).  It may be possible for you to develop the experience you need by leveraging the Roslyn CTP: msdn.microsoft.com/.../roslyn

  • Anonymous
    June 20, 2012
    Jurgen, Thank you very much for your answer. Do you have any example of implenting it with Roslyn. I was googling this morning without much luck. Thanks

  • Anonymous
    July 02, 2012
    Thanks Hani, Do you have any examples that show how to re-host the document outline pane? I'd really like to incorporate this feature in my re-hosted designer implementation code.msdn.microsoft.com/Workflow-Studio-df1d7dc0.

  • Anonymous
    July 05, 2012
    Oliver, I don't have any samples of the Roslyn integration, but one of my PMs has done some investigation on this and could discuss the approach with you.  Feel free to send me a note: JWillis...microsoft.com

  • Anonymous
    July 06, 2012
    Christopher, I just published a sample that illustrates how the outline view could be enabled in rehosted scenarios: code.msdn.microsoft.com/Support-of-WF-45-Designer-68212ed2

  • Anonymous
    July 13, 2012
    Awesome Hani. Many thanks! Will be incorporating these 4.5 features in my version in the near future.

  • Anonymous
    October 01, 2012
    can I edit the DisplayName property of a FlowDecision in Rehosted Workflow Designer, I tried to do It but I didn't succeed

  • Anonymous
    October 02, 2012
    Yes, users can edit the DisplayName property of a FlowDecision in rehosted scenarios. What is the error/behavior that you are observing?

  • Anonymous
    March 05, 2013
    Is it possible to highlight/change the color of the Activity connector in the Rehosted workflow designer. So that we can show the executed path of the workflow in visual tracking. For e.g. http://goo.gl/LF2AI

  • Anonymous
    June 10, 2013
    The comment has been removed

  • Anonymous
    April 24, 2014
    Why not just recreate this as an open source project around Rosyln? All of this seems hacked together now. The part we all think is really cool is the UI. We should just recreate that around Rosyln and EF and be done with it.