The official source of product insight from the Visual Studio Engineering Team
Many friends of mine have been asking me what my team is working on these days. I finally have an opportunity to share with all of you the really cool stuff we’ve been working on for the past many months.
My team built the Windows Simulator enabling users to debug Metro style apps for Windows 8 in a Windows environment.
There are three primary ways to debug a Metro style app.
There are certain features and traits in Metro style applications that helps them stand out compared to classic windows applications. For a better understanding of Metro style applications, I strongly recommend viewing the BUILD session by Jensen Harris on 8 traits of great Metro style apps before you start writing any Metro style applications.
The Windows Simulator is really handy when you need to verify how Metro style applications measure against these traits. I will introduce them here briefly and later we will have a detailed blog post on each of them.
Under the hood the Windows Simulator is a Remote Desktop Session into your local machine.
Developers need to be careful while modifying the state of the operating system in the Simulator because any changes in the Simulator will be reflected on the local machine itself. Multiple instances of Visual Studio and Expression Blend share the same instance of the Windows Simulator.
To debug an Metro style application using Windows Simulator, Open the application project in Visual Studio and choose Simulator from the debugging options in the Visual Studio toolbar.
Or you can enable Simulator from the Debugging tab of Project Property Pages.
After selecting Simulator to debug the application, simply press F5 or start debugging from the tool bar to launch a Metro style application in the Windows Simulator.
To stop debugging choose "Stop Debugging" from the Debug menu of Visual Studio.
Open the project in Expression Blend and then switch to the Platform panel and choose the Simulator as the Deploy target.
Then press F5 to launch application in Windows Simulator.
This feature is very useful to test Touch responsiveness for the application on developer machines that do not have touch devices. The Simulator supports single finger touch, tap and hold, pinch and zoom, and rotation. The touch controls are available in the Simulator Palette.
To switch out of touch emulation mode and back into mouse mode, select the mouse pointer. To learn more about Touch Emulation, see this blog entry.
Metro style applications should support Landscape and Portrait modes. Visual Studio templates are pre-configured for default behavior for landscape and portrait modes.
Without using an actual tablet device it is not easy to test the application in Portrait and Landscape mode. The Simulator is your friend here.
It is very easy to test the Landscape and Portrait modes using the rotation controls on the Simulator Palette.
Windows 8 can run on PCs of different screen sizes and Resolutions. Metro style applications should adjust to accommodate various screen sizes and resolutions. Using The Simulator it is very easy to test applications for different screen resolutions. You can use the "Change Resolution" button on the Palette to choose a resolution. The availability of resolutions in the Palette depends upon the supported resolutions of your video card.
Almost all the contracts in Metro style applications disappear once they lose focus or hit a breakpoint in debugger. It is not possible to debug contracts on your Local Machine without the Simulator. The Simulator is running a different desktop session, so when a breakpoint is hit in the debugger it does not result in a loss of focus in the simulator session.
I hope that you will find Simulator handy in time of need :), please post comments if you have any questions or feedback.
To learn more about developing Metro style applications for Windows 8 I highly recommend following //BUILD presentations.
8 traits of great Metro style apps Platform for Metro style apps Tools for building Metro style apps
Thanks, Navneet Gupta Software Design Engineer, Visual Studio
Hmmm...simulator is not emulator right ?
so I can't developer metro apps on a Win7 machine right ?
Nice Navneet, Will try this weekend
@Guest ... the developer tools to develop Metro style apps for Windows 8 requires, WinRT and other features that are unique to Windows 8.
How do I resize Simulator window? When entering "Portrait" mode Simulator resizes to fit the screen. After that the size does not change for the "Landscape" mode, the window is very small and does not resize automatically. Is there any way to increase window size for Landscape mode? Thanks
This is so cool! - Awesome Stuff - Experience Metro Style Apps via the Windows Simulator - WaytaGo Microsoft!! :)
Thanks @Anil :)
@Denis, thanks for your question, the Simulator window can be resized from bottom left rounded corner, just hover the mouse over there and it turns into double headed arrow to resize.
After rotation we keep the aspect ratios and width and height, sometime we resize the window after rotation to fit it to screen.
Software Design Engineer, Visual Studio
Interesting and useful.
I want to know is it an intended behavior. There is no ARM device now, i would like to test my ARM package and run it on simulator. One could assume that is what the simulator is about right.
VS2011 builds ARM package, but could not run it on simulator, it says ...VCLibs.ARM.11.appx failed to install for the following reason: Cannot install package microsoft.vclibs... , because it requires arch ARM.
Thanks for your question Snekithan.
The key usage scenario of the Windows Simulator is to provide a simulator for different screen sizes, touch input, and other peripherals that might not be available on developers’ machines. It is not a cross-architecture emulator. If this functionality is important to you, please provide that feedback in Connect at http://connect.microsoft.com/.
My Windows Simulator stopped working all of a sudden.
I get the following error when i debug my metro application using the simulator
"Unable to start simulator, the current operating system version is not supported by Windows Simulator" i use windows 8 consumer preview and vs11 beta.
My Windows Simulator stopped working...
I get the following error:
"Unable to start simulator. Cannot process request because the process (2796) has exited"
I use Windows8 ReleasePreview 64bit English and Visual Studio Express 2012 RC.
"Unable to start simulator, the current operating system version is not supported by Windows Simulator"
I'm on Win 8 & VS 11 Beta..
@Bala, @Viscoli @Sahaswaranamam
Please provide little more details, e.g. did you upgrade the computer from Windows 7 to Windows 8? Are you using x86 or amd64 version of Windows etc.