如何在 C# 中添加对程序集的引用? [英] How to add a reference to assembly in C#?
本文介绍了如何在 C# 中添加对程序集的引用?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我收到错误:
system.windows.controls.control"类型定义在未引用的程序集中".
the type 'system.windows.controls.control' is defined in an assembly that is not referenced".
如何添加对程序集的引用?
How to add a reference to assembly?
推荐答案
为了完整起见,万一您没有使用 Visual Studio(您没有指定),您可以添加对 csc
使用 /r:代码>编译器选项.与
任务.
元素类似msbuild
中的 >
For completeness, and in the unlikely event that you are not using Visual Studio (which you didn't specify), you can add assembly references to csc
using the /r:
compiler option. Likewise with the <References>
element of the <Csc>
task in msbuild
.
这篇关于如何在 C# 中添加对程序集的引用?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文