无法解析此引用。无法找到程序集程序

2023-09-04 08:55:43 作者:壞丶囡囡

每次我建立我的解决办法,我得到这个错误信息;

Everytime I build my solution I get this error message;

警告3无法解析此引用。无法找到   集结号StandardClassLibrary,版本= 1.0.0.0,文化=中立,   的ProcessorArchitecture = MSIL检查,以确保装配上存在   磁盘。如果此引用需要由您code,你可能会得到   编译错误。 StandardClassLibrary

Warning 3 Could not resolve this reference. Could not locate the assembly "StandardClassLibrary, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL". Check to make sure the assembly exists on disk. If this reference is required by your code, you may get compilation errors. StandardClassLibrary

所以,我的应用程序有一些项目 StandardClassLibrary 就是其中之一。上述消息是一个警告,因为据我可以告诉它不会对我的解决方案产生影响。

So my application has a number of projects of which StandardClassLibrary is one. The above message is a warning and as far as I can tell it does NOT have an impact on my solution.

不过,我宁愿它不会在那里,以防万一......

But I would rather it not be there, just in case...

推荐答案

您最有可能得到这个消息时,该项目指向它已经不存在了装配的老位置。既然你能一次建造它时,大会已经被复制到您的斌\调试 / 斌\发布文件夹,这样你的项目还是可以找到一个副本。

You most likely get this message when the project points to an old location of the assembly where it no longer exists. Since you were able to build it once, the assembly has already been copied into your bin\Debug / bin\Release folders so your project can still find a copy.

如果您在解决方案资源管理器中打开项目的参考节点,应该有一个黄色图标旁边的参考。删除引用,并从正确的位置重新添加。

If you open the references node of the project in your solution explorer, there should be a yellow icon next to the reference. Remove the reference and add it again from the correct location.

如果你想知道它是从引用的位置,你必须在文本编辑器中打开的.csproj文件并查找 HintPath 为组装 - IDE中由于某种原因不显示这些信息

If you want to know the location it was referenced from, you'd have to open the .csproj file in a text editor and look for the HintPath for that assembly - the IDE for some reason does not show this information.

 
精彩推荐
图片推荐