[.net] C# - Referencing to another project
Hi, I am very new to C#. I have a created some common code within a project that I can use with any of my other projects/solution. However, this code is stored in a path outside to the current solution. Although I can add the project to the solution, is there a way to reference to those code like you can in C++?
i.e.
#include "..\..\myCommonCode.h"
Go to solution explorer and right click on the project references folder and select Add Reference. Go to the browse tab on the dialog box that comes up (it might take a while for that to happen) and browse to the component you wish to reference.
If you wish to reference source files instead of whole assemblies, you can Add → Existing Item in the solution explorer. Note that by default it copies the file into your solution - click the drop-down to the right of the Add button to Add As Link.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement