SplitView Menu in Universal Windows (UWP) – Part3

uwp split view drawer

In part 1 (SplitView Menu Control – Part 1) I showed code for implementing my SplitView Menu control in a simple ‘standard’ scenario.
In part 2 (SplitView Menu Control – Part 2) I showed code for implementing my SplitView Menu control with custom container styling and custom item templates.
As mentioned in the first two parts of this series, the ‘Universal Windows Platform’ (UWP) is the platform that drives the new Windows 10 apps, and this series demonstrates my implementation of the SplitView menu, and is a component with source code available from my GitHub repository here: https://github.com/deanchalk/SplitViewMenuUWP
The third and final scenario is detailed below, and in this demonstration we are using a custom DataTemplateSelector to allow each individual menu item to pick up its own data template for unique styling across all menu items
Scenario 3 – styling individual menu items with a Custom DataTemplateSelector.

Here is the XAML in the main page

Here is the DataTemplateSelector implementation

Here is the ‘code behind’ binding code

And here is the main ViewModel

Here is what it looks like. Again – as in scenario 2 I haven’t paid any attention to the quality of the styling – the emphasis has been in demonstrating the power of the DataTemplateSelector

DataTemplateSelector implementation - large screen size

So there you have it, my SplitView hamburger menu for Windows 10 UWP apps.
I hope you find this article series interesting. Don’t forget to comment below, and also don’t forget to checkout the full source code at my Git repository here
All the best, and feel free to contact me if you wish to discuss any XAML-based development projects or issues.
You can also link with me on LinkedIn : ​https://www.linkedin.com/in/deanchalk/

About the author

Dean Chalk

I am a freelance (contract) Microsoft WPF developer, specialising in challenging, high-performance user interface development. I have been working exclusively on enterprise WPF app development since 2006, and I have been a part of some of the most demanding WPF projects ever created withing the Investment Banking / trading industry.