在WPF中,有时需要判断当前是否处于设计模式,以屏蔽设计器执行构造函数里面的部分功能
public static bool IsInDesignMode(this Control control)
{
return System.ComponentModel.DesignerProperties.GetIsInDesignMode(control);
}
在WPF中,有时需要判断当前是否处于设计模式,以屏蔽设计器执行构造函数里面的部分功能
public static bool IsInDesignMode(this Control control)
{
return System.ComponentModel.DesignerProperties.GetIsInDesignMode(control);
}
本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。