On Saturday I downloaded Embedded Visual C++ 4, Service Pack 4 for eVC++, the Pocket PC 2003 SDK, the SmartPhone 2003 SDK, the Mobile Application Development Toolkit, ActiveSync 3.8, the Smartphone 2003 SDK SPDPS Update for eVC++4.0 SP4, Windows Mobile 2003 Second Edition Developer Resources, and Windows Mobile 2003 Second Edition Emulator Images for Smartphone.
First of all I just tried downloading the Smartphone 2003 SDK, the Mobile Application Development Toolkit, and the Smartphone images. I installed them and wrote my very first application. Unfortunately when I ran it in the emulator, I got a “Not Supported Exception” on the line of code that setup the Menu on the form. So I assumed that I’d somehow gotten an old version of the .Net CF on the emulator image, but since I’d downloaded all the newest images I was confused… So I decided to install the PPC 2003 SDK, and the Windows Mobile 2003 Developer Resources. But that didn’t help. So I downloaded the rest of the tools and thought I’d try again. Unfortunately that meant that I’d have to uninstall all the other tools before I could install eVC++. And that mission was going to have to wait for another day.
Eventually today I got tired of people asking me “So have you written an app for your phone yet?” so I decided I’d do the installs. About 1/2 way through the installs I thought “Heck, why don’t I just google for +’NotSupportedException’ +’Compact Framework’ +’Menu’ – maybe someone else has had the same problem.” So I searched, and I found.
The first result was from a Quick Start on GotDotNet – and it explained everything. I found out that while the designer in VS.Net lets you do anything you like with the menu’s, the framework is not so forgiving. On a SmartPhone, you can only have 2 main menu’s, and the first one is simply not allowed to have any submenu’s. This is the way the UI’s on Smartphones are supposed to be designed so that they remain consistant across applications. So I understand the reasons, but I just wish that Microsoft would have thrown a meaningful error like “This isn’t supported because the first/left menu on a Smartphone cannot have any sub-menus”. That would have told me EXACTLY what I’d done wrong!
Anyway, so I quickly swapped my menu’s around so that they fitted in with the “best (and only way you’d get it to work) UI practices”, and voila! My first mobile application running on my Smartphone actually works. It simply pops up a message box that says “Hello!”, but its a start. 😀