Noodling Network Nodes - Diagraming with the NetworkView custom WPF control
- Posted: May 02, 2011 at 6:00 AM
- 8,959 Views
- 1 Comment
Loading User Information from Channel 9
Something went wrong getting user information from Channel 9
Loading User Information from MSDN
Something went wrong getting user information from MSDN
Loading Visual Studio Achievements
Something went wrong getting the Visual Studio Achievements
If you're working on a project where node diagraming plays a part, yet Visio or a commercial product is overkill, check out NetworkView: A WPF custom control for visualizing and editing networks, graphs and flow-charts hosted on CodeProject [Insert standard "CodeProject is just an awesome resource for projects, code and ideas" line here]
I've not seen a control like this in a while that's both free, source available and pretty complete. I liked how the sample projects not only worked (which is a good thing) but included polished touches like this help window.
What's even better than the control is the depth the article goes into.
"This article examines the use and implementation of a WPF custom control that is used to display and edit networks, graphs and flow-charts.
NetworkView, as I have called it, was inspired by and has many similarities to standard WPF controls such as ItemsControl and TreeView. The article and the sample code show how to use the control from XAML and from C# code.
This article is arranged in two main parts.
Part 1 examines
NetworkViewusage with walkthroughs of the two sample projects. This part and the reference section are enough if you just want to use
Part 2 goes into detail on the implementation. This will be useful if you want to make your own modifications to
NetworkViewor if you want to understand my approach to developing a complex WPF custom control.
At the end of the article is a reference section that describes the public properties, methods and commands exposed by
In previous articles I have covered a number of WPF techniques: use of adorners, zooming and panning,binding to UI element positions and most recently drag-selection of multiple items.
NetworkViewand the sample applications make use of all these techniques. I won't be covering these techniques in detail here. Instead, where appropriate, I'll refer back to previous articles.
NetworkViewis intended to be backed with an application-specific view-model. ...
From concept through implementation this 27 page article hits all the high points and beyond.
The included source downloads and runs with no issues. Here's a snap of the Solution
The code seems logical organized and is easy to follow.
And this snip shows how easy it can be to use.
If you need the control, or just want to see how someone would develop something like this, the article and source are an interesting read.