问题
In Visual Studio 2012 in Solution Explorer window have doubled file names (sorry for no screenshots - here is the link http://floomby.ru/s1/uaxC8K). In the same time it's all right in File Explorer and in project file (http://floomby.ru/s1/WaxCv8).
It's really annoying thing and cant find the reason why is this happening. What can be done to prevent such behavior?
回答1:
Still can't describe how to prevent, except it's just use the Visual Studio 2012 merge tool more accuratly. But here is the solution to get rid of duplicate entries in Solution window.
First remember somehow all name of duplicated files (PrtScr or smth else)
Unload the project (call context menu on project name, item "Unload Project")
Edit "ProjectName.xxproj" (call context menu on project name, item "Edit Project.xxproj")
Ctrl+F, paste the name of duplicated file, choose Find All. Look in Find Results window for absolutely identical entries of project files and remove one of them (https://docs.google.com/file/d/0B0NKNNSBiGejeV8wZ3g0WEYzcTA/edit?usp=sharing).
Save changes and Reload Project
回答2:
Another way is that
- Exclude duplicate files from project
- Click on "Show all files" button on top of solution explorer
- Click again on "Show all files" button on top of solution explorer (this time you should see only one excluded file)
- Include file again
You can do this on folders too
来源:https://stackoverflow.com/questions/15660884/doubling-file-names-in-visual-studio-2012