2011-10-02 63 views
15

我試圖從Phone 7移植我的應用程序,並找不到控制處於設計模式時檢測的方式。WinRT中有'IsInDesignMode'屬性嗎?

明白了 - Windows.ApplicationModel.DesignMode.DesignModeEnabled

+16

你應該說: 「知道了」並將其放入下面的答案表格中,並在網站允許我時將其標記爲已接受噸,使你的問題在技術上得到回答。 – BoltClock

回答

25

我使用這個:

if (Microsoft.Devices.Environment.DeviceType == DeviceType.Emulator) 

_isInDesignMode 
    = Windows.ApplicationModel.DesignMode.DesignModeEnabled 

檢查當前的發展狀況

相關問題