YOUR FEEDBACK
Craig Balding wrote: Bruce I read your comment and couldn't quite understand how it related to the p...

SYS-CON.TV
TOP MICROSOFT .NET LINKS


New Device Development Features in Visual Studio 2008
Visual Studio 2008 will migrate them to work on Windows Mobile 5.0 Smartphone using the .NET CF 2.0 runtime

The Device Security Manager
Continuing with our effort to help you test your code more efficiently, the second trickiest area developers had to deal with was executing code on devices with different security configurations. Every device developer at some point will realize that the certificates and security policies on the device control code execution. While we can't simplify those policies and processes, we can certainly provide tools that make it easier to understand and deal with these challenges. One way to deal with them is to have lots of devices in your test labs with different security configurations and test your applications on each of them. A simpler and cheaper way is to take advantage of the new Device Security Manager in Visual Studio 2008 that can change the security configuration for your target device at a click of a button so that you can quickly test your applications on different security settings and configurations (see Figure 5).

This tool can be launched from the Tools Menu followed by clicking Device Security Manager. In Figure 6 you can see that this tool is currently connected to a Windows Mobile 5 Smartphone Emulator and displaying the security configuration it currently has.

Emulator images usually ship with an unlocked security configuration that makes it easy to deploy and test applications; real devices will very likely be one of the other configurations listed on the screen. To see the effect of how your application will behave in a different configuration all you have to do is select the configuration of interest and deploy to the device.

In a matter of a few seconds that emulator image will be provisioned to work like a two-tier device and when you run your application you'll experience exactly what your customers do using a similarly configured device, all without you having to build an inventory of real devices.

Automation in the Device Emulator Manager
The Device Emulator Manager first shipped with Visual Studio 2005. It made it easy to see all the emulator images on your machine and provided the ability to quickly launch and cradle emulator images. Clearly that was useful, but manual in nature. Every time you had to launch or cradle or shut down and image, you had to manually do these tasks using the Device Emulator Manager. In Visual Studio 2008 the Device Emulator Manager can be fully automated, which means you can write simple scripts or code that you can run in conjunction with your unit tests to connect and disconnect one emulator after another.

Another enhancement in the Device Emulator Manager also makes it simple to clone emulator images. Once you have an emulator running, right-click on that node and select "Save As" shown in Figure 7.

This will prompt you to save the configuration of the emulator in a simple XML file in the "My Device Emulators" folder. It will also show this new emulator in the Device Emulator Manager. You can then edit this file to change the characteristics of the emulator and quickly build a list of emulators with various configurations.

Device Emulator Enhancements
The version of Device Emulator that ships with Visual Studio 2008 is version 3.0. Version 2.0 of the emulator shipped with the Window Mobile 6 SDKs and was also made available for download standalone from Microsoft Downloads. The performance gains should certainly be the most visible benefit to all developers moving from Version 1.0. But apart from working on performance Device Emulator also added capabilities to emulator hardware and peripherals such as battery, speakerphone, headset, and car kit.

Of all these features, Battery Emulation has been my favorite. I recollect talking to many developers who had to wait for hours for device batteries to drain enough to test how their code worked in low-battery conditions. For example, when the battery in the device went down, say, 20%, they wanted to start saving some critical data gracefully. The only way to test this before was with a real device - waiting patiently for that moment of joy when the battery level hit the desired level. The Device Emulator makes it a charm to test these scenarios. Coupled with the new state and notification APIs in Windows Mobile, you can use the Device Emulator to send a low-battery signal to the Emulator Image, which will then send a notification to your application to handle that event. And in a matter of seconds you'll be able to test the behavior of your application under different battery conditions (see Figure 8).

And to make things even easier in Version 3.0 you don't have to launch the properties page manually to change the battery state. You can now automate that part too. Just like the Device Emulator Manager, the Device Emulator supports automation and using a script or code you can alter the battery state while your application and emulator are running.

A Broad Choice of Supported Platforms
Visual Studio 2008 provides the most comprehensive choice of Windows Mobile and CE platforms for developers to target and continue to support both managed (VB, C#) and native (C++) development. Along with the Pocket PC 2003 and Smartphone 2003 SDKs that we shipped in Visual Studio 2005, we now also include the Windows Mobile 5.0 SDKs in the box. To develop for Window Mobile 6, you just have to download the most recent SDK from the Web and it will plug into Visual Studio 2008. In Visual Studio 2008, Smartphone 2003 is for a native project only since .NET Compact Framework 1.0 projects aren't supported and Smartphone 2003 only supports a .NET CF 1.0 runtime. If however you have any projects that you want to open, Visual Studio 2008 will migrate them to work on Windows Mobile 5.0 Smartphone using the .NET CF 2.0 runtime.

Visual Studio 2008 also introduces a more usable version of the new project dialog designed to make it easier to navigate multiple SDKs, runtimes, and application types as well as a link to help discover new SDKs and emulator images.

As you can see in Figure 9, we allow the ability to select a platform, select a version of .NET Compact Framework (2.0 or 3.5), and the application type all from one single screen.

And the best part of Visual Studio 2008 is that it will work perfectly well with Visual Studio 2005 side-by-side on the same machine to help make a smooth transition from 2005 to 2008.

Conclusion
I hope that with this article I was able to highlight how Visual Studio 2008 will greatly impact your ability to ship robust device applications faster to your customer and demonstrate a potential way to save the cost of procuring expensive devices by using the emulator and other features instead.

Our team will be glad to hear your feedback and thoughts on how we can continue to help provide you with the best development experience for smart device development. You can reach us using our team blog at http://blogs.msdn.com/vsdteam/, provide feedback using device forums at http://forums.microsoft.com/MSDN/default.aspx?ForumGroupID=11&SiteID=1, or by using the Connect Feedback System at http://connect.microsoft.com/default.aspx.

About Amit Chopra
Amit Chopra is the release program manager for the Visual Studio for Devices team. He also manages the sustained engineering efforts for eMbedded Visual C++ 4.0 and Visual Studio 2003. He can be contacted at achopra@microsoft.com.

MICROSOFT .NET LATEST STORIES
As a long-time PB developer, I have successfully created or maintained many PB applications for clients and for myself. Since day one, I was impressed with the ease with which applications can be created using PowerBuilder. Although I had been exposed to Visual Studio and other client/...
TeamExpand, a developer of products complimentary to Microsoft Visual Studio Team System (VSTS), announced the commercial version of its TX Chrono, a timesheet tracking application targeted at software development organizations standardizing on the Visual Studio .NET environment. Besid...
China’s new anti-monopoly law went into effect August 1 and China-based Evermore Software, an Office wannabe, would love to haul Microsoft into court. It says it’s collecting evidence and has suggested to MarketWatch that the integration between Office and Windows might be just...
Developer Express announced the immediate availability of its reporting platform for WinForms and ASP.NET – the XtraReports Suite v2008 vol 2. Built and optimized for Visual Studio, the DevExpress suite of reporting components allows software developers to deliver cutting-edge capabi...
Poland’s Office for Competition and Consumer Protection (UOKiK) has complained to the European Commission about Microsoft Windows being on laptops to the exclusion of Linux. It suspects collusion between Microsoft and the laptop makers that Microsoft allegedly greases with rebates, a...
SUBSCRIBE TO THE WORLD'S MOST POWERFUL NEWSLETTERS
SUBSCRIBE TO OUR RSS FEEDS & GET YOUR SYS-CON NEWS LIVE!
Click to Add our RSS Feeds to the Service of Your Choice:
Google Reader or Homepage Add to My Yahoo! Subscribe with Bloglines Subscribe in NewsGator Online
myFeedster Add to My AOL Subscribe in Rojo Add 'Hugg' to Newsburst from CNET News.com Kinja Digest View Additional SYS-CON Feeds
Publish Your Article! Please send it to editorial(at)sys-con.com!

Advertise on this site! Contact advertising(at)sys-con.com! 201 802-3021


SYS-CON FEATURED WHITEPAPERS

ADS BY GOOGLE
BREAKING NEWS FROM THE WIRES
Microsoft Corp. and Nikon Corp. have signed a patent cross-licensing agreement to further the develo...