This project is read-only.

How do I set the selected link for modern window.

Jun 5, 2013 at 5:03 PM
Edited Jun 5, 2013 at 5:03 PM
The selected link property is available inside modernmenu.
My main window code looks something like this.

<mui:ModernWindow + some initialization
    <mui:LinkGroup DisplayName="Welcome">
            <mui:Link DisplayName="Introduction" Source="/Pages/Introduction.xaml" />
    <mui:LinkGroup DisplayName="Layout">
            <mui:Link DisplayName="Wireframe" Source="/Pages/LayoutWireframe.xaml" />
            <mui:Link DisplayName="Basic" Source="/Pages/LayoutBasic.xaml" />
            <mui:Link DisplayName="Split" Source="/Pages/LayoutSplit.xaml" />
            <mui:Link DisplayName="List" Source="/Pages/LayoutList.xaml"  />
            <mui:Link DisplayName="Tab" Source="/Pages/LayoutTab.xaml" />

Now, I want to set the selected linkgroup and link programatically from viewmodel to the main window. How do I achieve this?
Jun 7, 2013 at 9:20 AM
i failed todo this, have a look at this thread to see what i already tried (last entry):
Jun 7, 2013 at 6:14 PM
You need to set the ModernWindow.ContentSource property to any of the existing link sources. The modern menu will automatically update its selected link and parent link group. There's no need to select a link group.

Please note that this works fine as long as the link sources are unique among all link groups.
May 7, 2014 at 1:37 PM
Edited May 8, 2014 at 1:43 PM