找不到元数据文件“.dll" [英] Metadata file '.dll' could not be found
问题描述
我正在处理 WPF、C# 3.0 项目,但出现此错误:
I am working on a WPF, C# 3.0 project, and I get this error:
Error 1 Metadata file
'WORK=- ToolsVersionManagementSystemBusinessLogicLayerinDebug
BusinessLogicLayer.dll' could not be found C:-=WORK=- Tools
VersionManagementSystemVersionManagementSystemCSC VersionManagementSystem
这是我引用我的用户控件的方式:
This is how I reference my usercontrols:
xmlns:vms="clr-namespace:VersionManagementSystem"
<vms:SignOffProjectListing Margin="5"/>
每次构建失败后都会发生这种情况.我能得到编译解决方案的唯一方法是注释掉我所有的用户控件并重新构建项目,然后我取消注释用户控件,一切都很好.
It happens after every failed build. The only way I can get the solution to compile is to comment out all my user controls and re-build the project, and then I uncomment the usercontrols and everything is fine.
我已检查构建顺序和依赖项配置.
I have checked build orders and dependencies configurations.
如您所见,它似乎截断了 DLL 文件的绝对路径...我已经读到长度存在错误.这是一个可能的问题吗?
As you can see, it seems to have truncated the DLL file's absolute path... I have read that there is a bug with the length. Is this a possible problem?
这很烦人,必须评论、构建和取消注释,构建变得非常烦人.
It's very annoying and having to comment, build, and uncomment, the build is becoming extremely tiresome.
推荐答案
我刚刚遇到了同样的问题.Visual Studio 没有构建被引用的项目.
I just had the same problem. Visual Studio isn't building the project that's being referenced.
- 右键单击解决方案,然后单击属性".
- 点击左侧的配置.
- 确保它无法找到的项目的构建"下的复选框被选中.如果已选中,请取消选中,点击应用并再次选中复选框.
- (可选)您必须针对解决方案属性的发布和调试模式执行此操作.
屏幕截图说明:
- 他们说一张图片值一千个字.点击 GIF 放大,希望它会很容易理解:
这篇关于找不到元数据文件“.dll"的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!