.net 应用程序的自定义安装程序

发布于 2024-11-05 02:47:27 字数 340 浏览 0 评论 0原文

我需要创建一个自定义安装程序,支持法语、德语、西班牙语、意大利语、波兰语、俄语、英语、中文(普通话脚本),以及为基于 .net 的应用程序添加更多语言。

该安装程序还需要能够检查目标系统是否安装了 adobe。如果目标系统没有 adobe 或者版本低于所需版本,则应从 CD 安装。如果确实如此,则绕过该步骤。

安装程序还需要提示用户浏览到系统上的任何位置以选取将放置在安装文件夹中的文件。

安装程序还需要在添加删除程序列表中注册该程序。

是否有一个自定义安装程序可以完成所有这些任务,或者我是否需要从头开始构建一个应用程序?

想法...想法???

感谢您抽出时间...

I need to create a custom installer that supports French, German, Spanish, Italian, Polish, Russian, English, chinese (mandarin script), more languages to be added for a .net based application.

This installer also needs to be able to check whether the target system has got adobe installed or not. If the target system doesnt have adobe or is a lower version than required then it should install from the CD. if it does then bypass that step.

The installer also needs to prompt the user to browse to any location on the system to pick up a file which will be place in the installation folder.

The installer also need to register this program in the add remove programs list.

Is there a custom installer that can do all of these tasks or do I need to build an application from scratch for it?

Thoughts... ideas???

Thanks for your time...

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

她如夕阳 2024-11-12 02:47:27

简短的回答:是的,所有这些事情都可以完成,其中大多数都很容易。

WiX 或 NSIS 可能是您最好的两个免费选择。 NSIS 的大部分功能都使用插件架构,但插件是文本文件,因此下载它们应该没有问题。但是,如果您的公司对许可感到“有趣”,那么请尽早检查每个插件的相关许可证 - 大多数都是完全免费使用的,但法律有时可能无法理解这一点......

请在下面找到指向相关部分的指针文档,以便您可以下载它(顺便说一下,我感受到了您的痛苦!)

语言支持

请参阅 Docs

允许用户选择文件并复制它

您将需要 InstallOptions 插件。这允许您在安装向导中创建一个额外的页面,可以提示信息。它允许各种控件,其中之一是文件资源管理器控件(在链接中搜索 FileRequest)。

要复制文件,您不能简单地使用File指令,因为它会从安装介质中提取并复制文件,并且不会作用于目标计算机上的文件。

相反,您将需要一个插件 - 例如 WinAPI 周围的这个包装器。或者,使用 CopyFiles 指令。

在添加/删除程序中注册程序

这是 WiX 和 NSIS 中的标准。

检测 Adob​​e 是否已安装。

NSIS 能够检查注册表项是否存在或命名文件是否存在,这是检测已安装程序的两种常规方法。

Short answer : Yes, all those things can be done, most of them easily.

WiX or NSIS are probably your two best free options. NSIS uses a plugin architecture for most of it's functionality, but the plugins are text-files, so you should have no problems downloading them. However, if your company is "funny" about licensing, then check the relevant licenses for each plugin early on - most are completely free to use, but Legal can fail to understand this sometimes...

Please find below pointers to the relevant sections of the documentation, so you can get it downloaded (I feel your pain by the way!)

Language Support

See Docs

Allow user to select a file and copy it

You will need the InstallOptions plugin. This allows you to create an extra page in your install wizard which can prompt for information. It allows various controls, one of which is a file explorer control (search for FileRequest in the link).

To copy the file, you cannot simply use the File instruction, as that extracts and copies files from the installation media, and will not act on files on the target computer.

Instead, you will need a plugin - e.g. this wrapper around the WinAPI. Alternatively, use the CopyFiles instruction.

Register program in Add/Remove programs

This is standard in both WiX and NSIS.

Detect Adobe is installed.

NSIS has the ability to check if registry keys exist, or named files exist, which are the two normal methods of detecting installed programs.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文