Possible to create a "linked" copy of a project in Visual Studio?

215 views Asked by At

I'm wondering if there is an easy way to create a "linked" copy of a project in Visual Studio 2010 or 2012. What I mean is, I already have my C# library project with all of my files in it (used to create TFS Checkin Policies for VS 2010). Now in order for me to have my checkin policies work on VS 2012, I need to change the references to reference the new v11.0 Team Foundation dlls. Since I still want to update and use my checkin policies on VS 2010, instead of changing the references in my project, I want to create a new project that will use the new v11.0 references, but still reference the actual files stored in the original project; so it is essentially a linked copy of the original project.

I know that I can do this manually by creating my new project, and then going Add Existing Item, pointing to the other project's files, and choosing "Add As Link". The problem with this is that when I create new files and add them to the original project, they don't automatically get picked up and added to this new project; I have to remember to go in an "Add As Link" the new files in the new project.

I know after creating a XNA Windows Game project you can choose to create a XBox or Windows Phone copy of the project, which then creates a "linked" copy of the project that automatically picks up new folders and files added to the Windows project (exactly what I described above and am looking for).

So is there a way for us to do this ourselves for regular C# library classes in Visual Studio? Or is the "Create Copy Of Project For Xbox 360 / Windows Phone" type of setup doing something funky that we can't replicate, or replicate easily?

Any suggestions are appreciated. Thanks.

1

There are 1 answers

1
FrostyFire On

You can't In visual studio. Why not just write the code to import the required files you have created as it needs them, from the directory of the other project. Like DLL Import, or something.