开发者

Detect DesignTime in WP7 code

开发者 https://www.devze.com 2023-02-07 01:32 出处:网络
simple question, does anyone know how to detect whether code is executed design-time with WP7? The usual Silverlight solutio开发者_如何学JAVAn of HtmlPage.IsEnabled doesn\'t work in this context.Try u

simple question, does anyone know how to detect whether code is executed design-time with WP7? The usual Silverlight solutio开发者_如何学JAVAn of HtmlPage.IsEnabled doesn't work in this context.


Try using the DesignerProperties.IsInDesignTool boolean property.

You will need to import the System.ComponentModel namespace to use this.

0

精彩评论

暂无评论...
验证码 换一张
取 消