ClickOnce 和 GAC

发布于 2024-08-21 08:36:14 字数 1166 浏览 4 评论 0原文

我有 WinForms 应用程序 .net 3.5。我在具有多台客户端计算机的 Intranet 中使用 clickonce 部署它。我在内网 Web 服务器 (http://desbiz/CarwinClickOnce) 中发布应用程序。

在开发人员环境(我的电脑)中,我的应用程序使用 GAC 程序集,例如 Fk.Security.Common.dll v.1.0.0.0。

在“发布”选项卡中 -> WinForms 应用程序 csproj 的属性中的应用程序文件,我将值 Include 设置为 Fk.Security.Common.dll 引用。

现在,

某些客户端计算机在 GAC 中具有 Fk.Security.Common.dll v.1.0.0.0 引用,

其他客户端在 GAC 中没有 Fk.Security.Common.dll v.1.0.0.0 引用

如果客户端使用 ClickOnce 安装 winform 应用程序存在以下问题:

1.) 如果 Fk.Security.Common.dll v.1.0.0.0 参考位于 GAC 中,则 ClickOnce 中包含的 Fk.Security.Common.dll v.1.0.0.0 参考不适用。

问题:ClickOnce 中包含的 Fk.Security.Common.dll v.1.0.0.0 参考中的编译代码可能比 GAC 中的 Fk.Security.Common.dll v.1.0.0.0 参考中的代码更新更多解决

方案:卸载 Fk.Security GAC 中的 .Common.dll v.1.0.0.0 参考,并在 GAC 中安装 ClickOnce Publish 中包含的 Fk.Security.Common.dll v.1.0.0.0 参考...

(如何卸载/安装程序集GAC 使用 ClickoNce????)

2.) 如果 GAC 中没有 Fk.Security.Common.dll 引用,则 ClickOnce 中包含的 Fk.Security.Common.dll v.1.0.0.0 引用适用。没问题。

注意:客户端计算机上的用户具有管理员权限。

关于这个问题有什么解决办法吗?

提前致谢。

I have WinForms application .net 3.5. I deploy it using clickonce in intranet with several client machines. I publish application in intranet web server (http://desbiz/CarwinClickOnce).

In developer environment (my PC), my application uses GAC assemblies, like Fk.Security.Common.dll v.1.0.0.0.

In tab Publish -> Application files in Properties of WinForms application csproj, I set value Include for Fk.Security.Common.dll reference.

Now,

some client machines have Fk.Security.Common.dll v.1.0.0.0 reference in GAC

others client have NOT Fk.Security.Common.dll v.1.0.0.0 reference in GAC

If the client installs the winform application using ClickOnce there are this issues:

1.) If Fk.Security.Common.dll v.1.0.0.0 reference is in GAC, the Fk.Security.Common.dll v.1.0.0.0 reference included in ClickOnce not apply.

Problem: perhaps compilde code in Fk.Security.Common.dll v.1.0.0.0 reference included in ClickOnce is more update than code in Fk.Security.Common.dll v.1.0.0.0 reference is in GAC

Solution: uninstall Fk.Security.Common.dll v.1.0.0.0 reference in GAC, and install in GAC the Fk.Security.Common.dll v.1.0.0.0 reference included in ClickOnce Publish...

(how can I uninstall/install assemblies in GAC using ClickoNce????)

2.) If Fk.Security.Common.dll reference NOT is in GAC, the Fk.Security.Common.dll v.1.0.0.0 reference included in ClickOnce apply. No problem.

note: the user in client machine has Administrator permissions.

Any solution about this issues ??

Thanks in advance.

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

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

发布评论

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

评论(3

情话已封尘 2024-08-28 08:36:14

ClickOnce 无法安装或卸载 GAC 中的文件。

您编写了 Fk.Security.Common.dll 吗?如果是,则增加版本号(v.1.0.0.1)并重新编译。当您引用它时,将“特定版本”属性设置为“True”,并将“版本”属性设置为新版本号。这应该可以解决您的问题,而无需从每个人的 GAC 中卸载旧程序集。

ClickOnce cannot install or uninstall files in the GAC.

Did you write the Fk.Security.Common.dll? If so, increase the version number (v.1.0.0.1) and recompile it. When you reference it, set the "Specific Version" property to "True" and the "Version" property to your new version number. This should fix your problem without having to uninstall the old assembly from everyone's GAC.

绳情 2024-08-28 08:36:14

在您的 Visual Studio 项目中,单击引用的程序集 (Fk.Security.Common.dll),然后在属性窗口中将 Copy Local 属性设置为 True (我假设您是使用 ClickOnce)

In your Visual studio project click on the referenced assembly (Fk.Security.Common.dll) and in the properties window set the Copy Local property to True (I assume you are using ClickOnce)

若相惜即相离 2024-08-28 08:36:14

无法安装或运行该应用程序。该应用程序需要
安装程序集 Telerik.Windows.Data 版本 2012.1.215.40
首先在全局程序集缓存 (GAC) 中

当我忘记在 Visual Studio 中将解决方案配置从“调试”更改为“发布”时,我遇到了同样的错误。发布之前。

Unable to install or run the application. The application requires
that assembly Telerik.Windows.Data Version 2012.1.215.40 be installed
in the Global Assembly Cache (GAC) first

I had same error when I forgot change solution configuration from "Debug" to "Release" in the Visual Studio. Before publish.

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