50.2. Mobile Application Deployment

Deployment of device applications has been a much-debated topic, and numerous white papers have been written about how to package an application for installation. In the past, packaging an application required considerable fiddling within Visual Studio to generate an installer for a mobile application. Although Visual Studio 2008 provides good support for building CAB files, several steps are still required to deliver an easy-to-install application. This section looks at how you can use CAB files to install your application, and describes how a desktop MSI installer can really make your application look professional.

50.2.1. CAB Files

The easiest way to deploy your application is via a CAB file, which is essentially a compressed file that contains all the assemblies and resources that your application requires in order to run. It can also contain registry settings that may need to be applied during installation. To install an application, the CAB file needs to be downloaded to the device before being executed. Executing the CAB file decompresses the contents, installs the application, and performs any installation activities. The final stage is to remove the CAB file from the device. If you use a storage card to deploy a CAB file to multiple devices, it is a good idea to make the card read-only so the CAB file does not get removed.

Visual Studio 2008 contains a project type called a Smart Device CAB Project, which is listed under Setup and ...

Get Professional Visual Studio® 2008 now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.