Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Visual Studio 2008 saving files gets slow

I've looked for some other articles on this problem and even tried some of the ideas in this thread; however, nothing has solved the issue yet. So, on to the issue.

Something happens when working in Visual Studio (usually C#) that causes the IDE to become a bit wonky when saving a file. I will be working along just fine for a while then at some point I notice that every time I save a file (Ctrl+S) it becomes very slow.

The behavior I notice is this; I hit save in some fashion (Ctrl+S, menu, etc...) and in the status bar I see the word Searching show up. It looks like it is scanning through all of the loaded namespaces for something, although I have no idea for what or why it is doing so. It causes a real hiccup in workflow since typically I will hit Ctrl+S often and keep typing.

I have been unable to track down what exactly causes this to start happening. It has happened in multiple project types (web, WPF, console).

Has anyone seen this behavior or have any suggestions?

like image 709
palehorse Avatar asked Sep 19 '08 16:09

palehorse


3 Answers

I know the question is old but this may help others who are having the same issue.

I to had a problem with VS 2008 taking long time to save some files. Not all files, just a few files. Hitting Ctrl+Swould take any where from 30-120 seconds.

I figured out it was on pages having external JavaScript. So I selectively commented them out and tried saving and found the offender.

Culprit was Google translate javascript code.

It starts with <script src="//translate.google.com/translate_a...

Notice the // at the beginning of the src. All other external scripts that started with http:// had no problem, I changed the // to http:// and the problem was solved.

It seems VS is trying to get the file locally if the path is not http. I don't know what it does, but this fixed the problem for me.

like image 101
Yash Gadhiya Avatar answered Sep 23 '22 01:09

Yash Gadhiya


I've had a problem similar to this happen before. Are you using an plugins like ReSharper or DevExpress?

like image 25
Adam Driscoll Avatar answered Sep 21 '22 01:09

Adam Driscoll


Did you disable intellsense? We've seen that bog down all sorts of things in Visual Studio.

like image 44
Mark Avatar answered Sep 25 '22 01:09

Mark