Solution Folder Not Showing in Visual Studio 2010

2020-05-24 19:17发布

问题:

I created a new Blank Solution in Visual Studio 2010, then I did an Add New Project, and the Solution node no longer shows in the Solution Explorer.

Further, when I try to do a second Add New Project, I get the error:

Cannot add the item because the item to add it to is not a solution folder or the solution.

What happened to the Solution node?

Where is it, so that I can highlight it and add a second project to my solution?

回答1:

In order to view Solution explorer. Go to View > Solution explorer.

Or press Ctrl+Alt+L.

And solution window will appear.



回答2:

Tools, Options, Projects and Solutions, check "Always show solution"

Trivial update:

I'm on Visual Studio 2010, Ultimate edition. Windows 2008 R2, Enterprise edition, SP1. My guess the difference between @arrocharGeek screenshot and mine is I turn off all the vista/win7/2008r2 eye candy to make it look "normal."



回答3:

You need to show the solution as follows:

  • Navigate to Tools | Options
  • Check the "Show all settings" checkbox in the bottom left of the Options dialog
  • Navigate to the "Projects and Solutions" | "General" section
  • Check the "Always show solution" checkbox

The "Solution solution-name (n projects)" will now show, and you can highlight that node to Add New Project from there.


Trivial Update: My VS 2010 is SP1Rel, and I am on Win7 Enterprise SP 1: