
Organize Projects and Solutions #3
Chapter 1, Master Projects and Solutions
|
15
HACK
A good solution to the file reference issue is to create a single folder that
contains all of the assemblies that are referenced through file references.
This way, all the developers on a project can retrieve the latest versions of
these assemblies from the same location, whether through a common shared
directory or source control.
Project References
A project reference refers to another project in your solution; for instance,
you might have a Windows Forms project that references a class library
project. When the Windows Forms project is built, it will create a copy of
the class library assembly and move it to your output directory.
What makes a project reference superior to an assembly reference is that
Visual Studio will watch for any changes to the other project. When there
are changes, you will automatically get a new copy of the assembly in your
build directory. Visual Studio will also use project references to infer project
dependencies. In the case of a Windows Forms project referencing a class
library project, Visual Studio will determine that the class library project
needs to be built before the Windows Forms project since the Windows
Forms project depends on the output of the class library.
Project references also avoid problems when sharing the project between
systems or when working with projects under ...