Using Visual Studio .NET to Package an Application


You can use Visual Studio .NET to create a CAB file for your application. This is definitely the quickest and easiest way to build a CAB file for your application. It is also the least flexible way to build a CAB file. Later in this chapter we will discuss a more flexible way to create a CAB file, but for now let's discuss CAB file generation with Visual Studio .NET.

Visual Studio .NET provides a simple UI-driven way to build a CAB for your application. You can simply select the Build CAB File option on the Build menu, which will build a CAB file in the <project_name>/cab/<build_type> directory, " <project name > " being the name of your project and " <build_type> " being either the debug or the release, depending on the current build mode settings.

There are three other files that are created in the <project_name>/obj/<build_type> directory: a batch file, a configuration file, and a dependencies file. The batch file is named BuildCab.bat and can be used to rebuild the CAB file. This is particularly useful if you have made changes to the configuration file and you do not want the configuration file to be regenerated by Visual Studio .NET by choosing the Build CAB File option again. The configuration file's name depends on the name and target platform of the project. For example, the project named CalcDotNet target for the Pocket PC platform would be named CalcDotNet_PPC.inf . The configuration file is described in detail in the "Using the CAB Wizard to Package an Application" section. The dependencies file is named Dependencies_PPC.inf . This file is used to record the dependencies for the CAB file. When the CAB is being installed, the installer will check that the dependencies in this file have already been installed on the device.

That is all there is to it. Now you have a CAB file that can be installed on a device.



Microsoft.NET Compact Framework Kick Start
Microsoft .NET Compact Framework Kick Start
ISBN: 0672325705
EAN: 2147483647
Year: 2003
Pages: 206

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net