无法安装程序集以进行缓存? [英] Cannot install assembly to cache?

查看:186
本文介绍了无法安装程序集以进行缓存?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图将程序集添加到Visual Studio 2010命令提示符下的缓存中。我收到此错误无法将程序集添加到缓存:尝试安装没有强名的程序集。我正在从名为ListTasks2的WCF服务应用程序中添加ListTasks2.dll程序集。我从未在同名项目中遇到此问题,所以为什么现在引发问题?

I am trying to add an assembly to the cache on Visual Studio 2010 Command Prompt. I get this error "Failure adding assembly to the cache: Attempt to install an assembly without a strong name". I am adding a ListTasks2.dll assembly from a WCF Service App called ListTasks2. I never had this issue with a similarly-named project, so why is it raising an issue now?

注意:我尝试在Visual Studio中对其进行签名,但仍然没有工作。我想知道这是否可能是权限问题。我使用了不同的用户凭据,并且能够添加一个程序集。问题是我加载了VS解决方案,并且该项目对程序集进行了签名。我应该只创建一个密钥对吗?

NOTE: I tried signing it in Visual Studio and it still doesn't work. I wonder if it might be a permission issue. I used different user credentials and was able to add an assembly. The catch is that I loaded a VS Solution, and that project signed the assembly. Should I just create a key pair?

推荐答案

只有强名称的程序集才能安装到GAC中。有关如何创建强名称程序集的信息,请参见如何:用强名称签名程序集。

Only strong-named assemblies can be installed into the GAC. For information about how to create a strong-named assembly, see How to: Sign an Assembly with a Strong Name.

这篇关于无法安装程序集以进行缓存?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆