找不到 System.Windows 程序集 [英] Can not find System.Windows Assembly

查看:25
本文介绍了找不到 System.Windows 程序集的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这是我们得到的错误:

错误 1 ​​在未引用的程序集中定义了类型System.Windows.Point".您必须添加对程序集System.Windows, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e"的引用.C:PacManPacManPacManPacManTestsUnitTest1.cs 65 13 PacManTests

Error 1 The type 'System.Windows.Point' is defined in an assembly that is not referenced. You must add a reference to assembly 'System.Windows, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e'. C:PacManPacManPacManPacManTestsUnitTest1.cs 65 13 PacManTests

我们在单元测试项目中遇到这个错误,它无法找到 System.Windows 程序集,但我们的主项目可以找到程序集并正常运行.

We get this error in our unit test project which cant find the System.Windows Assembly but our main project can find the assembly and run it fine.

有人对我们可以在何处或如何引用 System.Windows 来解决此问题有任何意见或建议吗?

Does anyone have any input or advice on where or how we can reference System.Windows to fix this problem?

推荐答案

就我而言,没有可用的 System.Windows 参考.
我必须包含对 WindowsBase

In my case there was no System.Windows reference available to pick up.
I had to include a reference to WindowsBase

这篇关于找不到 System.Windows 程序集的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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