DCSIMG
Another minor C#/C++ difference - adding existing files - Miscellaneous Debris

Miscellaneous Debris

Thoughts and Snippets

Another minor C#/C++ difference - adding existing files

Another minor detail that bit me for a few minutes today. I'm posting this so I'll see it and remember, and possibly lodge it in other people's consciousness.

Using Visual Studio 2005, adding an existing .cs file to a C# project will cause a copy of that file to be created in the project directory. If I want to link to the original file, I need to explicitly choose Add As Link from the dropdown on the Add button.

C++ projects, however, have the opposite behavior. Adding an existing item in a different folder will add a link to the original file in the original location. To create a copy, manually copy it to the project dir.

That is all.

תוכן התגובה

JOKER666 כתב/ה:

HTML --ב  register איך מכינים    

# November 19, 2007 1:23 AM

Gle כתב/ה:

Thanks I had the same problem and had to learned this the hard way too.

# July 21, 2009 6:46 PM
שלח תגובה

(שדה חובה)  

(שדה חובה)  

(אופציונלי)

(שדה חובה) 

Please add 8 and 3 and type the answer here:


Enter the numbers above: