DISABLEADVTHORTCUTS=1 禁用所有快捷方式

发布于 2024-08-19 11:53:01 字数 257 浏览 2 评论 0原文

我们有一个在启动时运行的应用程序,允许在安装后更改许多已安装的文件。我们尝试通过在 Orca 中设置 DISABLEADVTSHORTCUTS=1 属性来关闭自我修复模式。但是,设置此属性后不会创建任何快捷方式。我看到的所有信息都表明我们应该能够通过设置 DISABLEADVTSHORTCUTS=1 创建“非广告”快捷方式。有什么想法吗?

我已验证如果 DISABLEADVTSHORTCUTS 保持不变,快捷方式是否已正确创建。

We have an application to be run on startup that allows many installed files to be changed after installation. We are trying to turn off the self-healing mode by setting the DISABLEADVTSHORTCUTS=1 property in Orca. However, no shortcuts are being created when this property is set. All the information I've seen indicates that we should be able to create "non-advertised" shortcuts with DISABLEADVTSHORTCUTS=1 set. Any ideas?

I have verified that the shortcuts are created correctly if DISABLEADVTSHORTCUTS is left unchanged.

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

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

发布评论

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

评论(4

旧故 2024-08-26 11:53:01

如果您在 Visual Studio 2008 中创建安装和部署项目,有一个非常巧妙的技巧可以使您的快捷方式不公开:

在 UI 编辑器中添加一个文本框面板。使所有文本框不可见。将属性之一设置为“DISABLEADVTSHORTCUTS”而不是 EDITAx。将值设置为“1”。您的快捷方式将不会被公开。

我想将此归功于我从那里偷来的人,但我似乎找不到原始链接。

If you're creating a Setup and Deployment project in Visual Studio 2008, there's a very slick trick to make your shortcuts NON-advertised:

Add a textboxes panel in the UI editor. Make all the textboxes invisible. Make one of the properties 'DISABLEADVTSHORTCUTS' instead of EDITAx. Make the value '1'. Your shortcuts will be non-advertised.

I'd like to give credit for this to whomever I stole it from, but I can't seem to find the original link.

留蓝 2024-08-26 11:53:01

不确定这是否有帮助,但您可以尝试一下:以编程方式而不是手动进行。

源帖子:Windows 开发人员中心(通过discussweb.com)

"将 WiRunSQL.vbs 文件复制到项目目录中。现在,在 Visual Studio 2005 中,在解决方案资源管理器中选择安装项目。选择其属性。在属性窗口中,将以下脚本添加到 PostBuildEvent 属性。

cscript //nologo "$(ProjectDir)WiRunSql.vbs" "$(BuiltOuputPath)" "INSERT INTO Property(Property, Value) VALUES ('DISABLEADVTSHORTCUTS', '1')"

此脚本项目构建完成后将自动运行,并将 DISABLEADVTSHORTCUTS true 值插入到应用程序 MSI 属性表中。”

如果您不知道在哪里可以找到 WiRunSQL.vbs 文件,我可以从以下站点获取它: svn.nuxeo.org

Not sure if that helps, but You might give it a try: do it programmatically instead of manually.

Source post: Windows Developer Center (via discussweb.com)

"Copy the WiRunSQL.vbs file into your project directory. Now, in Visual Studio 2005, select your setup project in the solution explorer. Select its properties. In the property window, add the following script to PostBuildEvent property.

cscript //nologo "$(ProjectDir)WiRunSql.vbs" "$(BuiltOuputPath)" "INSERT INTO Property(Property, Value) VALUES ('DISABLEADVTSHORTCUTS', '1')"

This script will automatically run once the project has been built and will insert the DISABLEADVTSHORTCUTS true value into the application MSI property table."

If You don't know where to find the WiRunSQL.vbs file, I got it from the following site: svn.nuxeo.org

悟红尘 2024-08-26 11:53:01

您无法禁用自我修复,那么为什么不首先安装非广告快捷方式呢?

您无需指定用于创建此包的内容,但以 WiX 为例,

如果您尝试使用以下命令来处理现有安装包,则 只需设置 Shortcut/@Advertise='no' Orca,请参阅快捷表的文档。广告快捷方式将在 Target 列中包含类似 ProductFeature 的内容,而非广告快捷方式将使用类似 [APPLICATIONFOLDER]MyApp.exe 的内容或[#MyApp.exe]

You can't disable self-healing, so why not just install non-Advertised shortcuts to begin with?

You don't specify what you're using to create this package, but with WiX for example you would just set Shortcut/@Advertise='no'

If you are trying to massage an existing installation package with Orca, see the documentation for the Shortcut table. An advertised shortcut will have something like ProductFeature in the Target column, while a non-advertised shortcut will use something like [APPLICATIONFOLDER]MyApp.exe or [#MyApp.exe]

箜明 2024-08-26 11:53:01

自我修复可能很难调试和理解,但您需要了解其原因才能有效管理它。

请检查如何确定导致重复 Windows Installer 自我修复的原因?,以全面审查此核心 MSI 问题。仅通过更改快捷方式无法对其进行可靠管理。

这是另一篇包含核心 MSI 信息的文章:使用 MSI 的企业优势

Self-healing can be hard to debug and understand, but you need to understand its causes to be able to manage it effectively.

Please check: How can I determine what causes repeated Windows Installer self-repair? for a comprehensive review of this core MSI issue. It can not be managed reliably simply by changing your shortcuts.

Here is another article with core MSI information: The corporate benefits of using MSI.

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