【发布时间】:2012-02-16 12:13:31
【问题描述】:
- IDE:VS2010
- Framework.net:4.0
我在 Visual Studio 2010 下创建了一个 c# dll 项目,其中包含几个公共类,我想在另一个 dll 项目中使用它的类,但用 vb.net 编写。
在 vb.net dll 项目中,我引用了构建的 c# dll,但无法导入 c# 类。 c# dll的命名空间甚至无法识别。
我必须做什么才能看到我的 c# 课程? 如果可以的话。
我的 c# dll 的类示例(命名空间 MyCSharpDll):
namespace MyCSharpNamespace {
public class MyCSharpClass {
public void Test() {}
}
}
我的 vb.net dll 文件中的示例:
Imports MyCSharpDll.MyCSharpNamespace
VS2010 指出一个错误,指出 MyCSharpDll 未知或没有公共成员。
谢谢。
【问题讨论】:
标签: c# vb.net visual-studio-2010 dll reference