Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

adding items to Visual C# (Express 2010) project without copying them to project folder

Is that possible? I noticed that every time I add an item (code or XAML file) it gets copied to project folder. This way I cannot keep reusable files separately. I could build a dll out of them but that would be an overkill and in the general case it's very inconvenient, as for each project I'm only interested in a subset of all my reusable classes.

like image 612
andriej Avatar asked Apr 29 '11 11:04

andriej


4 Answers

When you add an 'Existing Item' you can choose to 'Add As Link' by clicking the triangle next to the Add button in the Add Existing Item screen. Maybe that answers your question?

like image 96
Tim Geerts Avatar answered Oct 08 '22 02:10

Tim Geerts


enter image description here

like image 35
Teoman Soygul Avatar answered Oct 08 '22 02:10

Teoman Soygul


You can add "links" in Visual Studio:

http://msdn.microsoft.com/en-us/library/9f4t9t92(v=vs.80).aspx

Select it from the drop down beside the "Add" button when you add an item.

like image 43
jvenema Avatar answered Oct 08 '22 00:10

jvenema


You can - when you go to add the file please notice the small down arrow on the Add button. If you select this arrow you have the option for adding the file as a link - and that is exactly what you get, so only a kind of shortcut is added to your project but with the same effect.

like image 30
REA_ANDREW Avatar answered Oct 08 '22 02:10

REA_ANDREW