How to find out, if your app is running in an emulator, or on a real device?

In July’s beta, Microsoft has moved this property from System.Environment to Microsoft.Devices.Environment namespace.

//enum DeviceType contains: Device, Emulator
this.IsEmulator = (Microsoft.Devices.Environment.DeviceType == DeviceType.Emulator);

Share and Enjoy:
  • Technorati
  • Digg
  • Facebook
  • del.icio.us
  • Live
  • Google Bookmarks
  • DotNetKicks
  • DZone
  • TwitThis
  • Blogosphere News
  • Blogplay
  • LinkedIn
  • MisterWong
  • MisterWong.DE
  • MSN Reporter
  • MyShare
  • RSS
  • StumbleUpon
  • Suggest to Techmeme via Twitter
  • Tumblr
  • Twitter
  • Webnews.de
  • Yahoo! Bookmarks
  • Yigg

Leave a Reply