开发者

Why my type or namespace name for project within solution isn't recognized?

I'm stuck with a project that I can't get "seen" in a reference 开发者_如何学运维by other projects in the same solution.

This is the error: Error 2 Metadata file 'C:\Documents and Settings\user\Desktop...\bin\Debug.dll' could not be found.

I've added the reference of course, and added the using directive for the namespace where it's used in class files. I remove the file, save, restart, and start anew, and it persists. Any ideas? I've been searching for hours, and it seems as though this can be caused by many things, none of which pertain to me. :/

It's a simple set of three class libraries and one windows forms project in the solution, VS 2010 Express, C#.


Within the same solution, but not within the same project? Are you sure you've declared your classes as public? They're internal by default.


Is one of your projects using .net 4 Client Framework and the referenced one isn't?


Have you added a project reference or a DLL reference between the projects? IS the name of the assembly you are referencing, really Debug.dll?


This is a little old, but thanks to the advice here I found my problem.

One project was using ".NET Framework 4 Client Profile" and the other ".NET Framework 4". I switched them both to use ".NET Framework 4" and it works fine now.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜