Wed, November 16, 2005, 01:40 PM under
MobileAndEmbedded
I meet a lot of experienced .NET developers lately (including colleagues) that have focused on WinForms or ASP.NET or other .NET areas, but have never dabbled with the .NET Compact Framework. It doesn't take long before out conversation ends up in me providing information on how to get started with NETCF development. Here goes for future reference1. The very first thing to do is to install Visual Studio 2005 (it side by sides with earlier VS versions).
[ The Express editions are no good to you but Standard and above will do perfectly. There is also a stand alone SDK and you could even try Visual Studio.NET 2003 Professional or higher, but my advice is to get Visual Studio 2005. ]
2. (optional) If you are planning on targeting Windows Mobile 5.0 devices, then you also need to download the
Windows Mobile 5.0 SDK (i.e. for SmartPhone and PocketPC). In this case, you also need to get ActiveSync v4 (install this *over* your existing ActiveSync v3).
3. Create a new project via the normal route, but choose the “Smart Device” node and then the appropriate self-explanatory project type (e.g. “Device Application”). Note that VS2005 also supports creating apps that target Compact Framework v1.0 (there never was a NETCF v1.1). I recommend you stick with the v2.0 projects.
4. Drag a button on the form and add an event handler to it as you normally would, and type:
MessageBox.Show("It isn't that different, is it?")
.
5. Start debugging the application: note how you have to choose where to deploy your application (i.e. an emulator type), choose whatever you want (e.g. “Pocket PC 2003 SE Emulator” and then “Deploy”) and notice how your application runs and you can click the button to get your msgbox (this may take a few minutes if this is the first time you are deploying).
6. From the IDE, click the "Stop" to stop debugging your application (emulator remains running, but your application has exited).
7. (optional) There are also some platform considerations,
read these8. (optional) If you need to share/execute your CF code on the desktop,
see this.
9. (optional) For some links on how the NETCF differs from the full framework,
see here10. (optional) Remember the
netcf is not a strict subsetFrom here on, you can start developing that NETCF app you’ve always dreamed of :-)
You will run into issues and you will have questions. You are a smart guy/girl so,
before you ask me for help, check that your question isn't already answered in the FAQ (
old and
new), search the
netcf newsgroup via google and check that
OpenNETCF hasn't addressed the limitation you face. If you still haven't got a resolution, now you can seek support. Luckily there is a vibrant netcf community and for NETCF v2 the
MSDN forums rock.
Welcome to the world of mobile development. Isn’t it much more satisfying running your own creation on your pda/phone than on the desktop? The mobility space *will* take off big time in 2006. Good luck!