With the introduction of the .NET Compact Framework (CF) and the Smart Device Programmability features of Visual Studio .NET 2003, Microsoft has made it easier than ever before to develop applications for Pocket PC PDAs. Any developer who has used Visual Studio and either C# or Visual Basic .NET to build a Windows or Web application can now use the same tools to write applications for Pocket PC PDAs. But developing a proper PDA application requires more than knowing how to use a programming language, an IDE, and a class library.
Developers shouldn't think of a PDA as simply a tiny PC. There are obvious differences, and others that are not so obvious. If you are old enough to have programmed for some of the earliest PCs, these differences may seem like "deja vu all over again." In this article, I'll review the issues to consider before designing and building an application for the Pocket PC platform.
User Input and Output
One of the most obvious differences between the PDA and PC is the small screen on a PDA. Pocket PC screens are usually 240 pixels wide and 320 pixels tall, but the reality is that the usable application space is even smaller. According to Microsoft's Designed for Windows Mobile Software Application Handbook for Pocket PCs, applications are supposed to keep the standard NavBar at the top of the screen and the standard menu bar at the bottom. Whenever text input is needed, the required popup SIP (Soft Input Panel) subtracts another 80 pixels from the 320-pixel height.
So although the device's screen has a height of 320 pixels, a little more than half of it is completely usable for application specific information. Making an application's user interface fit in this tiny space will require some creative design and coding.
In addition to the screen size being smaller than even the lowest-end PC, the color depth is also smaller. Some newer Pocket PCs have 16-bit (64K) color depth, but many display only 256 colors, and some display only 16 levels of gray.
Another obvious difference is the lack of a physical keyboard. Some Pocket PC models have a "thumb keyboard," but if you've ever gotten an E-mail message from someone who uses a BlackBerry, you know that thumb keyboards aren't meant for serious text entry. Drop-down lists, MRU (Most Recently Used) lists, and spin boxes are all alternatives to consider for aiding data input.
Pocket PCs do have some unique features to consider for input. For example, they have a standard set of hardware buttons that can be used in applications. Allowing users to press a hardware button might work better than requiring them to press a software button with the stylus. Pocket PCs also have a voice recorder. Although foolproof voice recognition for input on a device is not quite ready for prime time, the voice recorder and built-in speaker do allow applications to save and play back audio files. Audio can work as a good alternative to text if the information doesn't need to be directly interpreted by software.
And finally, even after trying to convince users to go paperless, many still prefer printed reports. Printing from a Pocket PC application is far from plugging in a USB printer and coding up a few Printer.Print statements. Printing from a Pocket PC application requires working with C language-style APIs and third-party libraries.