Sep 9 2010

Is my Program running in the Emulator or on a Real Device

Category: Joel Ivory Johnson @ 08:10

There are times in which you would want to know whether or not your program is running in the Windows Phone emulator or on a real device. It's easy to determine on which your application is running with a single line of code. 

 

bool IsInEmulator = Microsoft.Devices.Environment.DeviceType == DeviceType.Emulator;

Tags: ,

Comments