VS2008,Windows Mobile的安装项目项目、Windows、Mobile

2023-09-07 03:30:29 作者:温柔说书人.

我使用Visual Studio 2008专业版。 我写的Windows Mobile应用程序,我想创建安装此应用程序。它是如何做的?

I'm using Visual Studio 2008 Professional Edition. I wrote an application for Windows Mobile and I would like to create the installer for this application. How does it do?

推荐答案

您需要在CAB文件中的应用程序打包起来。

You'll need to package your application up in a CAB file.

要做到这一点是很容易 - 你只需创建一个新的智能设备CAB项目(新Projet->其他项目类型 - >安装和部署)

To do this is quite easy - you just create a new "Smart Device CAB Project" (New Projet->Other project types->Setup and Deployment).

要开始 - 指定您希望从您的应用程序的EXE项目输出走在应用程序目录,以及任何其他相关DLL

To start with - specify that you want the output from your application's exe project to go in the Application Directory, along with any other dependent dlls.

您可能还需要为应用程序创建通过右键单击文件系统上的目标机器的图标,选择添加特殊文件夹 - >开始菜单文件夹,然后用鼠标右键再次单击开始菜单文件夹并选择创建新的快捷方式。现在的exe文件为您的应用点这个快捷方式。

You may also want to create an icon for your application by right clicking File System On Target Machine, selecting Add Special Folder->Start Menu Folder, then right clicking again in the Start Menu Folder and selecting Create New Shortcut. Now point this shortcut at the exe for your application.

根据项目的要求,也可能是希望创建一个桌面安装程序(MSI文件),用户可以将他们的Windows PC上,它指示ActiveSync来自动安装您的CAB文件时,Windows Mobile设备上直接运行通过从命令行调用ActiveSync的(CeAppMgr.exe)并将其传递一个INI文件引用您的CAB文件的下一个堵塞。基本上做到这一点。

Depending on the requirements of your project, it may also be desirable to create a desktop installer (msi file) that your users can run directly on their Windows PC, which instructs ActiveSync to install your cab file automatically when the Windows Mobile device is next plugged in. Basically this is done by calling ActiveSync (CeAppMgr.exe) from the command line and passing it an ini file referencing your cab file.

如果您需要在安装过程中做任何事情都要更复杂,也可以写一个自定义操作,其中驾驶室文件调用出另一个DLL(你写的)来执行需要发生的任何额外的步骤在安装过程中。

If you need to do anything else more complex during your installation, it is also possible to write a "custom action" where the cab file calls out to another dll (written by you) to execute any additional steps that need to happen during the install.

一个COM prehensive引导到上述所有可用这里

A comprehensive guide to all the above is available here