首页 > Windows开发 > 详细

WPF在win7运行时报'Initialization of 'System.Windows.Setter' threw an exception.'

时间:2017-06-24 17:11:16      阅读:358      评论:0      收藏:0      [点我收藏+]

写的一个WPF程序,在win10运行好好的,在win7就报‘Initialization of ‘System.Windows.Setter‘ threw an exception.‘

原来是xaml使用了xmlns:Themes="clr-namespace:Microsoft.Windows.Themes;assembly=PresentationFramework.Aero2"

并且dll引用了PresentationFramework.Aero2

那么只要改为

xmlns:Themes="clr-namespace:Microsoft.Windows.Themes;assembly=PresentationFramework.Aero"

dll引用改为PresentationFramework.Aero,就可以兼容win7了

WPF在win7运行时报'Initialization of 'System.Windows.Setter' threw an exception.'

原文:http://www.cnblogs.com/IWings/p/7073713.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!