Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Visual Studio 2010 closing a tab takes 8 seconds?

Anybody else's VS2010 is extremely slow when closing code editor tabs?

Opening a .cs file is instantaneous but closing a tab takes ~8 seconds. I have uninstalled Power Commands and the Productivity Power Tools, the only other installed extensions are ReSharper (disabling it did not help) and the Color Theme Editor. I do have the UI Automation Performance Fix installed.

I tried most suggestions from Visual Studio Optimizations question; made sure the settings are saved locally; disabled the outlining mode; disabled the Anti-Virus -- nothing helps.

Googling only finds generic "VS2010 is a pig" complaints back from the Beta1 times. I even tried installing a few recent hot-fixes from https://connect.microsoft.com/VisualStudio/Downloads (KB2201993, KB2123002, KB2106584, KB981107, B2268081) but nothing seems to help.

Any ideas anybody?

--UPDATE---

Another clue: it only seems to happen for some solutions but not for others! Why would it be solution-specific?!!

like image 812
Stop Putin Stop War Avatar asked Sep 15 '10 19:09

Stop Putin Stop War


4 Answers

Deleting .suo file helped!

Similar case was reported here but it involved a huge .suo file while mine was <1Mb

Another mention of similar problem can be found here in their case it was the debugger that was impacted.

Thanks to Sysinternals ProcessMonitor for the clue!

like image 58
Stop Putin Stop War Avatar answered Nov 15 '22 17:11

Stop Putin Stop War


I know you already tried disabling antivirus, but I wanted to post what worked for me. We're inflicted with Symantec Endpoint Protection where I work and I fixed the problem by excluding the solution's folder(s) from auto-protect. Closing file tabs in VS2010 used to take several seconds, now it's nearly instantaneous.

Here's how: Under your Symantec's Antivirus and Antispyware Protection -> Options -> Change Settings -> (tab) File System Auto-Protect -> Centralized Exceptions -> Add...[your folder(s)].

like image 38
RobertC Avatar answered Nov 15 '22 17:11

RobertC


After half a year suffering, I just discovered that adding the project's folder to Security Essentials' excluded files & folders list clears this problem for me. Removing the exclusion brings the problem back.

like image 6
Alex J Avatar answered Nov 15 '22 16:11

Alex J


I was having this same issue. used procmon to find that visual studio was slamming my solution's .suo file. I deleted that file and immediately my file closings are immediate. no more 60 second closing all files!!! Man, MS needs to fix that problem, It's very bad.

like image 1
Tony Avatar answered Nov 15 '22 15:11

Tony