是否可以使用c#在wpf中动态创建resourcedictionary? [英] Is it possible to dynamically create resourcedictionary in wpf using c# ?

查看:389
本文介绍了是否可以使用c#在wpf中动态创建resourcedictionary?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要通过代码隐藏动态创建资源字典并将其添加到relavent项目中。 ResourceDictionary名称应该像 English.xaml

I have a requirement to dynamically create resource dictionary by code behind and add it to the relavent project. The ResourceDictionary name should be like English.xaml

推荐答案

试试这个

http://wpfbox.wordpress.com/2007/ 03/06 / how-to-allow-full-customization-with-a-resource-dictionary-part-i / [ ^ ]



试试这个



http://www.wpfsharp.com/2012/01/26/how-to-load-a-dictionarystyle-xaml-file -at-run-time / [ ^ ]
Try This
http://wpfbox.wordpress.com/2007/03/06/how-to-allow-full-customization-with-a-resource-dictionary-part-i/[^]

Try This Too

http://www.wpfsharp.com/2012/01/26/how-to-load-a-dictionarystyle-xaml-file-at-run-time/[^]


这篇关于是否可以使用c#在wpf中动态创建resourcedictionary?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆