Reputation: 69
I've copied a Visual Studio solution over to a new computer. When I open up the solution, the one project that is in it is unloaded. When I reload the project it appears for a split second and then is immediately unloaded again.
I'm having this issue on two different machines, but not on the source machine or on any of the other machines that have a copy of this solution. This is happening on both a Windows 7 machine and a Windows 8.1 one, both running Visual Studio 2010.
Things I've tried:
Thanks!
Upvotes: 6
Views: 3552
Reputation: 31
It happends to me in VS 2022 with big and small solution (web and api) and it seems to be due "restoring" of packages -> nuget cant load everything or is confused. Part of our nugets are stored in Azure DevOps... that is probably what causing the issue.
Solution for me is to unlog from MS account in VS. Load solution, wait a bit and then log in back.
So expecting there could be other issue causing this ... but it looks like the main issue is when VS tries to restore packages and something went wrong. Unfortunetely there is no error message, no console log ... nothing visible.
Upvotes: 3
Reputation: 91
I found a solution which worked at least for me: I have both TFS and Git hosted projects, therefore I kept the TFS pending changes and git changes tool window open. When I close the git tool windows, everthing started working fine
Upvotes: 1
Reputation: 186
This happened to me this morning - I have the latest version of 2019 open.
This is a solution which I upgraded from 2017, at which point the problem started.
My first attempt to fix it was to open it from the project file, at which point it reopened in 2017, which I believe might be the root of the problem. When I opened to project file using 2019, the problem happened again.
I deleted the .git directory and now the solution stays open. I think the root solution is going to reside in the project file for the solution, but I wanted to put this out there for people still experiencing it
Upvotes: 1
Reputation: 1109
As of 2017-03-12, this happens to me every time I open an existing solution.
I have Visual Studio 2017 Enterprise installed side-by-side with Visual Studio 2015 Enterprise.
The only work-around that I have found is to open the solution a second time from within Visual Studio 2017. It stays open at that point.
I have no idea why this "disappearing act, open a second time" work-around is necessary at all - all I know is that it works for me.
I sure hope Microsoft fixes this annoying "feature" quickly.
Upvotes: 1
Reputation: 370
Not sure if you ever found a solution, but I had exactly the same problem and I fixed it after realising that the new machine didn't have ASP.NET installed on it, as it was the Visual Studio that comes coupled with SQL Server, and only contains BI tools - try and create a new project and see if ASP.NET is there, if not, there's your problem!
Upvotes: 2