Ed Clarke’s In a Nutshell

And He Needs Help Getting Out

Project References

Posted by edc73 on June 28, 2008

This issue keeps popping up in our environment, so figure I’d put out this quick tidbit:

When adding references to libraries that exist within the solution, you should make sure you add the reference via the Project tab, not the Browse tab.  This means you will have to have the target project loaded in the solution to add the reference.

If you don’t do this, command line builds will still be ok, but builds within the IDE can get all messed up due the the build order not being what it should be.  In general, you will get error messages indicating TypeA can not be converted to TypeA, which doesn’t make any sense.  What’s really happening is TypeA in the dll can not be converted to TypeA in the currently loaded project.

Once you fix the references, all should be good again.

Leave a Reply

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <pre> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>