views:

44

answers:

2

Would there be any reason that VS would prohibit you to "Add existing file" to lets say a folder inside an assembly?

Is it protected somehow? If so how and where is this done and how can I see if this is the case?

There are some missing .cs class files in one of these folders that should be included in this project and I try adding them back in and get nothing, nothing happens...it doesn't show them added in VS.

+1  A: 

Is the project file marked "read only" if you check its properties?

Anna Lear
Double-check the project file just in case.
Anna Lear
Also, try reloading the project. Or click the button at the top of the Solution Explorer that shows all files on disk and try including files through right-clicking them and selecting "Add to project".
Anna Lear
And if all else fails, manually edit the csproj file. :) (I really wish hitting 'enter' didn't submit the comment. Sorry about the comment spam.)
Anna Lear
@Anna - Don't forget you can go back and edit rather than commenting again :)
Basiclife
No, the project properties has no read only settings. I checked its source.
CoffeeAddict
A: 

Beyond the obvious that adding files/modifying the project is disabled while the project is running, there shouldn't be any reason not to be able to - Is the option greyed out/do you get an error?

Basiclife
It's not running. And when I right-click that folder and perform an "Add Existing File", I go browse to that file and chose it. The dialog closes and I see nothing happen. That folder in Solution Explorer still has the same contents and nothing additional was added.
CoffeeAddict
Do you have permissions to modify the location where the project lives? Is VS running as you or another user? Is there anything unusual in your setup and does this happen only with one specific project or any project you open?
Basiclife