Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

I've been trying to open some of the webpage/database solutions I made while working for my previous employer, to get a refresher on what they were, but for some reason Visual Studio Professional 2013 just decides to either crash while opening them, or crash when I try opening one of the C# files I made in them. I have no idea why it's doing this now, since it's been a little over a month since I made these files without any problems. There doesn't seem to be anything wrong with 2013 itself, either. Suggestions?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
233 views
Welcome To Ask or Share your Answers For Others

1 Answer

For VS2013: I've hit a similar problem every now and then and my fix is to delete the *.suo file and then open the solution.

The only time that has not worked was when an extension was playing up, in which case I opened VS in Safemode using the /safemode switch.

devenv.exe /safemode

Using the /log switch as noted in another answer is also a good idea if it turns out to be a misbehaving extension because that can help you track it down. The default location of the ActivityLog.xml file on my computer is "c:Users<username>AppDataRoamingMicrosoftVisualStudio<version>ActivityLog.xml" but you can also specify where you want the file to be:

Devenv /log PathNameOfLogFile

See the documentation for VS2013 (with links to other versions) at: /Log (devenv.exe)

I hope that helps.

For VS2015: Same solution, just the suo file is in a different place. VS2015 adds a ".vs" folder. Within that folder are other folders, one of which is named the same as your solution, within that folder is another folder named "v14" and within that one (finally) is a file called ".suo". Delete that file.

Example: your solution is called "Whatever". Starting from your "Whatever" folder the path to the suo is:

.vsSolutionNamev14.suo

If you can't see the ".suo" file, remember that it is a hidden file.

I've been using this PowerShell script for a few days to get rid of the .suo files after switching between git branches:

get-childitem -Include .suo -Recurse -force | Remove-Item -Force –Recurse

I've not had any problems with it so far, but no promises that it won't incinerate your laptop :) so use it carefully.

For VS2017: The path to the .suo is:

.vsSolutionNamev15.suo

My guess is the "v15" will keep incrementing in future releases.

I found another SO answer that covers some other solutions to VS issues, such as flushing the ReSharper cache if you are using that tool: Visual Studio displaying errors even if projects build.

... And VS2019 The path to the .suo is:

.vsSolutionNamev16.suo

When I started using VS2019 I got a lot of "errors" reported after a successful build of an existing project. The editor didn't like namespaces from other projects within the solution. Closing VS, deleting the .vs folder and restarting VS fixed it.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...