w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML videos Categories
How to do Databinding with Mahapps.Metro WindowCommands and Caliburn Micro?

I solved the problem with a workaround (that even looks more decoupled) using a ContentControl instead with a separate ViewModel instead of using the DataTemplate. DataTemplate works when it is used within the ContentControl's Content:

        <controls:MetroContentControl cal:View.Model="{Binding
MySeparateViewModel}" />

The cal:View.Model looks onto a property of my ShellViewModel. Hope this helps if someone else has the same problem to solve.

© Copyright 2018 w3hello.com Publishing Limited. All rights reserved.