Home » Microsoft Technologies

Custom designer for a Flowchart activity?

Can anyone point me in the right direction for developing a custom designer for a Flowchart activity? 

In actual fact, the Flowchart control we are using is a custom activity - it's not the regular .NET Flowchart activity, but our own creation with a collection for FlowNodes/etc.  We'd like to put a UI around it now as well ... mimicking the .NET Fllowchart designer.  Is that really possible, or extremely difficult?  It seems there's no real API or anything available for constructing the node connectors, arrows, etc.


1 Answer Found


Answer 1


I'm struggling with that too. Please see post http://social.msdn.microsoft.com/Forums/en-US/wfprerelease/thread/49d2aa2f-27bd-4c6c-a955-bfed7f6cbf74/#7f784d2a-12c1-4c21-b611-745fe9bdce67

Especially reply from Tim:


"There's a blog series I did on getting the most basic parts of ICompositeView working, however, it was hard slog, I didn't get very far, and there's lots of bugs, so I don't think it has been that useful to people looking for a simple solution. (sample bug:


Second option is downloading the State Machine source code from codeplex and using that as a basis for your own custom  flowchart. It is a complex sample code but full of features and much less buggy. Of course you don't have to modify State Machine if State Machine already solves your problem. If you do want to modify it, or encounter bugs with it you might be able to get some support via this forum.

[A last ditch option for those who want to be broken by future .net releases that I have seen people doing is interesting hacks in designer, like modifying the visual tree directly.]

But in summary - there is no really easy way to add the custom flowdecision feature to flowchart.


State Machine 4.0 link: http://wf.codeplex.com/releases/view/43586

Besides this, I've seen something done in .NET 3.5 with FreeFormActivityDesigner which would've been very useful for me (see methods exposed) but it belongs to System.Workflow.ComponentModel.Design and can't be used with .NET 4 activities and from what I see in post http://social.msdn.microsoft.com/Forums/en-US/wfprerelease/thread/dff6046c-b451-4ffc-b51d-137488c60617  the approach recommended is WorkflowItemPresenter (see WF 4 samples).

Currently I'm studying the code from StateMachine, see how far I get but like Matt Winkler says "Our goal was to have a robust, extensible freeform base that could be used to construct a number of different graph oriented workflow designers.  Unfortunately, we will not have time to complete that for vs2010" (http://social.msdn.microsoft.com/Forums/en-US/wfprerelease/thread/dff6046c-b451-4ffc-b51d-137488c60617) they didn't finish therefore not easy with VS2010.



<< Previous      Next >>

Microsoft   |   Windows   |   Visual Studio   |   Sharepoint   |   Azure