【问题标题】:What causes ClickOnce URLDownloadToCacheFile failed during installation?是什么导致 ClickOnce URLDownloadToCacheFile 在安装过程中失败?
【发布时间】:2009-11-14 08:43:54
【问题描述】:

通过 Firefox 安装 ClickOnce 应用程序时出现以下错误。同一台计算机上的 IE 不会发生这种情况。我发誓我以前通过 Firefox 安装过它。这是一台 Windows 7 机器。

The following properties have been set:
Property: [AdminUser] = true {boolean}
Property: [ProcessorArchitecture] = Intel {string}
Property: [VersionNT] = 6.1.0 {version}
Running checks for package '.NET Framework 2.0 (x86)', phase BuildList
Running external check with command 'C:\Users\luke\AppData\Local\Temp\VSDEF1A.tmp\DotNetFX\dotnetchk.exe' and parameters ''
Process exited with code 1
Setting value '1 {int}' for property 'DotNetInstalled'
Reading value 'Version' of registry key 'HKLM\Software\Microsoft\Internet Explorer'
Read string value '8.0.7600.16385'
Setting value '8.0.7600.16385 {string}' for property 'IEVersion'
The following properties have been set for package '.NET Framework 2.0 (x86)':
Property: [DotNetInstalled] = 1 {int}
Property: [IEVersion] = 8.0.7600.16385 {string}
Running checks for command 'DotNetFX\instmsia.exe'
Result of running operator 'ValueExists' on property 'VersionNT': true
Result of checks for command 'DotNetFX\instmsia.exe' is 'Bypass'
Running checks for command 'DotNetFX\WindowsInstaller-KB893803-v2-x86.exe'
Result of running operator 'ValueExists' on property 'Version9x': false
Result of running operator 'VersionLessThan' on property 'VersionNT' and value '5.0.3': false
Result of running operator 'VersionGreaterThanOrEqualTo' on property 'VersionMsi' and value '3.0': true
Result of checks for command 'DotNetFX\WindowsInstaller-KB893803-v2-x86.exe' is 'Bypass'
Running checks for command 'DotNetFX\dotnetfx.exe'
Result of running operator 'ValueNotEqualTo' on property 'DotNetInstalled' and value '0': true
Result of checks for command 'DotNetFX\dotnetfx.exe' is 'Bypass'
'.NET Framework 2.0 (x86)' RunCheck result: No Install Needed
Launching Application.
URLDownloadToCacheFile failed with HRESULT '-2146697211'
Error: An error occurred trying to download 'http://croppy.lukehunter.net/download/croppy.application'.

以下是来自 Microsoft 的操作指南,但这不适用于 Firefox。也没有发生重定向。

如果用户设置了 Internet Explorer 高级安全选项“警告如果 在安全和不安全之间切换 模式”在部署目标上 计算机,如果设置 URL 正在安装 ClickOnce 应用程序 从非安全重定向到 安全站点(反之亦然), 安装将失败,因为 Internet Explorer 警告中断 它。

【问题讨论】:

    标签: windows clickonce


    【解决方案1】:

    Internet Explorer 在后台从 dfshim.dll 调用 LaunchApplicationShOpenVerbApplication 过程,而 Firefox 插件-in(以及由 Visual Studio 2008-2010 创建的标准引导程序,也可能产生这种罕见的错误)使用不同的过时技术来启动 ClickOnce 应用程序。 (请注意,LaunchApplication 至少需要 .NET Framework 2 SP 2。)

    为避免此类错误,可以将 Internet Explorer 重定向到部署清单 (.application),将所有其他浏览器重定向到自定义安装程序 (.exe),如果需要,该安装程序将安装 .NET Framework,然后调用ShOpenVerbApplication.

    【讨论】:

      【解决方案2】:

      嗯,用IE安装,然后卸载后,我又可以通过firefox安装了。奇怪。

      【讨论】:

      • 是的,“Odd”只是总结了我作为用户使用 ClickOnce 的经验。对我来说,它只是过于复杂、不透明和脆弱。随时给我一个简单的.EXE。
      【解决方案3】:

      以下内容对我有用:

      在本地分发包中单击一次,在 clientCache 上生成了一个 web.config 文件,这就是问题所在,其中针对 CHROME 和 IE8 进行了如下更改,现在运行该文件:

      <clientCache cacheControlMode="UseMaxAge" cacheControlMaxAge="1.00:00:00" />
      

      【讨论】:

        【解决方案4】:

        我遇到过这个问题,解决它的方法是禁用防火墙。很遗憾,我不知道它是什么防火墙设置,我只是禁用了很多,它运行/安装没有问题。

        【讨论】:

          【解决方案5】:

          在这个问题上用尽防火墙选项后,我发现我的可执行文件指向了应用服务器的 IP 地址。当我更改站点部署并因此将可执行文件更改为服务器的 FQDN 而不是 IP 地址时,安装程​​序第一次工作。

          【讨论】:

            【解决方案6】:

            简单的解决方案,在 cmd 上执行 setup.exe /URL=http:///

            简单!

            【讨论】:

            • 请再次检查您的答案,或提供更多详细信息。遵循您的“简单”说明导致“无法识别“setup.exe”...”错误。
            猜你喜欢
            • 1970-01-01
            • 1970-01-01
            • 2015-10-26
            • 1970-01-01
            • 2011-04-04
            • 1970-01-01
            • 1970-01-01
            • 1970-01-01
            • 2015-11-09
            相关资源
            最近更新 更多