Wednesday, March 2, 2011

How to Detect Design time mode in Silverlight

 

I have read many blogs on this, they talk about checking things like HtmlPage.IsEnabled.

Personally I use Application.Current this will be NULL if you are in design mode.

public static bool InDesignMode()
{
return App.Current == null;
}

No comments:

Post a Comment