How to apply Metro Ligth Theme to StyleableWindow using xaml

How to apply Metro Ligth Theme to StyleableWindow using xaml

H. I’m new to using xceed components. i’d like to apply the metro light theme to my app but it was not being applied on my styleable window.

here is what i did:

in my app.xaml,

<ResourceDictionary>
<vm:ViewModelLocator x:Key=”Locator” d:IsDataSource=”True” />
<DataTemplate DataType=”{x:Type vm:MainViewModel}”>
<vw:initial />
</DataTemplate>
<ResourceDictionary.MergedDictionaries>
<xcd:MetroLightThemeResourceDictionary LicenseKey=”xxxxxxxx”></xcd:MetroLightThemeResourceDictionary>
<xcd:AllControlsResourceDictionary/>
<xctt:ToolkitMetroDarkThemeResourceDictionary/>
</ResourceDictionary.MergedDictionaries>

</ResourceDictionary>

and in the window i want to theme:

<xctk:StyleableWindow x:Class=”Web2Pdf.MainWindow”
xmlns=”http://schemas.microsoft.com/winfx/2006/xaml/presentation&#8221;
xmlns:x=”http://schemas.microsoft.com/winfx/2006/xaml&#8221;
xmlns:d=”http://schemas.microsoft.com/expression/blend/2008&#8243;
xmlns:mc=”http://schemas.openxmlformats.org/markup-compatibility/2006&#8243;
xmlns:local=”clr-namespace:Web2Pdf”
xmlns:view=”clr-namespace:Web2Pdf.View”
mc:Ignorable=”d”
xmlns:xctk=”http://schemas.xceed.com/wpf/xaml/toolkit&#8221;
xmlns:xcpt=”http://schemas.xceed.com/wpf/xaml/themes&#8221;
xmlns:xctt=”http://schemas.xceed.com/wpf/xaml/toolkit/themes&#8221;
Icon=”gnome_mime_application_pdf.ico”
Title=”Web2Pdf” Height=”250″ Width=”400″>

<view:initial />
</xctk:StyleableWindow>

i’ve been losing sleep for three nights because. of this. if anyone could help me it would be greatly appreciated.