Search code examples
c#project-referencedll-reference

c# Project reference


Reading MSDN's documentation, I was left uncertain.

Setting: I have project A referencing some dll X, and project B project-referencing project A, and requiring dll X as well.

Would I need to add a reference to dll X to both projects, or would the project reference do that for me?


Solution

  • You only need to add a reference to X when classes, methods, etc. of X are made available through A.

    If there is no public use of X in A, you don't need to reference it (although you would need it in your bin folder.