Get Updates VIA E-mail

Enter your email address:

Thursday, August 14, 2008

Best Windows Mobile Programming Tips and Techniques

The survey is divided into three parts covering Pocket PCs, Pocket PC Phone Editions, and Smartphones, though the questions are the same in each section. Comments have been edited for brevity and clarity.

Here's what the developers said:

Windows Mobile Pocket PC

What are the most useful software/programming tools you use when developing Pocket PC applications?

Hands down, Visual Studio has to be the best tool for developing Pocket PC applications. I use it exclusively and would not want to create apps any other way. The emulator goes a long way toward giving you instant feedback on how the application is going to look and behave on the device. While the emulator can not replace running the application in the actual environment, it does save a lot of time and headaches, and speeds up development because you don't have to transfer your application to the device for testing each time.


I use two sets of tools: Visual Studio .NET 2003 is great for developing applications quickly, for UI design, and for most general purpose development. I use Embedded Visual C++ 4.0 (SP3) for system extensions in C++, but it comes with a really useful set of tools for remote working on a device, like Remote Registry Editor and Remote Spy++ etc.

In addition to these I use SOTI remote Control software and a couple of freeware tools like on-device registry editing.

Visual Studio .NET is the best programming tool for the mobile enterprise solutions we develop in our company. Its advanced environment supporting a powerful form designer allows us to do the customization of our projects in a very simple way. Moreover it provides many new technologies, such as Web services, that were not allowed in the old eVB which we used to use before.

Visual Studio.NET 2003 enables a wide variety of applications to be built, all from within the one integrated environment. It has great features that let me debug while I'm testing my app on the actual device. Also, grab the latest PocketPC SDK 2003 from Microsoft Downloads, as this gives you emulators for the latest devices and supports VGA displays.

What are your favorite techniques/approaches/tricks that make developing Pocket PC applications easier/faster/better?

One of the things I have come to rely on is testing code on a real device. Yes, the emulator running on my PC is a very close match to the device (and its even better in Whidbey!), but I still prefer to have a physical device with a separate processor and its own memory to run my code. This allows me to use my PC separately, at full speed, for compile and debug.

I also tend to use two displays attached to my PC when coding. I have Visual Studio open on one display and the other is for help / web pages/ command prompt etc. I find this makes me significantly more productive.

Samples! Samples! Samples! You can never have enough of them. I keep all the code snippets I write, as well as Pocket PC / Smartphone SDK samples, and catalogue them for easy access. These are always useful.

Finally, it's not always what you know that counts—it's often more important to know who to ask. I keep a long list of web sites and maintain a list of active community contacts so that I can ask an expert ?'how to solve a particular problem.

I use static forms, threading, and also re-write Visual Studio Designer-generated code to improve performance. OpenCF has also been a big help with their code library and user forum. They have contributed beautifully to the Pocket PC community through the support and expansion of the Compact Framework.

Try and re-use as much of your previous work as possible. Also, keep each stage of the solution simple. I use classes to solve the smaller problems. This gives me greater flexibility to choose when and where I use those classes (and in which projects).