How to add more than one resource to a XAML window?

前端 未结 1 1907
醉话见心
醉话见心 2021-02-12 12:56

I have a little problem right now and I don\'t know how to fix it. I want to add two resources to a window. One is a XAML File style resource, the other a ValueConverter Class.<

相关标签:
1条回答
  • 2021-02-12 13:10
    <Window.Resources>
        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <ResourceDictionary Source="Resources\MyStyles.xaml" />
            </ResourceDictionary.MergedDictionaries>
    
            <local:MarginConverter x:Key="adjustMargin"/>
        </ResourceDictionary>
    </Window.Resources>
    
    0 讨论(0)
提交回复
热议问题