Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to stop right click dead-locking Visual Studio 2008

I have a very serious problem with Visual Studio 2008. Occasionally when I right-click (for go to definition, set next statement etc) when I'm debugging, Visual Studio will just dead-lock and go into not responding mode.

Has anyone had the same problem? Does anyone know how to solve it?

Edit: I'm using SP1 with a couple of hot-fixes.

like image 264
Mark Ingram Avatar asked Sep 24 '08 10:09

Mark Ingram


4 Answers

Problem:
Signed Applications/dlls load slowly in Vista. Visual Studio IDE 'Hangs' on offline/non-internet-connected workstations. Without internet connectivity the certificate revocation check times out and causes applications to hang. When debugging/stepping through code dlls are loaded as needed and this is when the revocation check is attempted and the VS IDE becomes unresponsive.

What this effects:
This effects all signed applications/dlls and is also the reason for Microsoft Word/Excel taking so long to open a simple document. Office applications, SQL Management Studio, Visual Studio, Web Applications that use a certificate.

Fix:
Disable checking of Publisher's Certificate Revocation

Via IE:

  1. Go to Internet Options in IE 7
  2. Then go to the Security Tab, scroll towards the bottom
  3. Uncheck the 'Check for Publisher's Certificate Revocation' checkbox
  4. Click OK

Via the registry:

  1. Open regedit
  2. Browse to the following key: HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\WinTrust\Trust Providers\Software Publishing
  3. To disable the check: Change the value of the State key to 146944 Decimal or 0x00023e00 Hexadecimal
    To re-enable the check: Change the value of the State key to 146432 Decimal or 0x00023c00 Hexadecimal

Alternate Fix:
Disable the Visual Studio Hosting Process:

  1. Open a project in Visual Studio.
  2. On the Project menu, click Properties.
  3. Click the Debug tab.
  4. Clear the Enable the Visual Studio hosting process check box.

Note: The Alternate Fix causes the loss of some debugging functionality.

Background:
Microsoft Connect Report

like image 146
Chris Andrews Avatar answered Nov 09 '22 08:11

Chris Andrews


This issue no longer occurs for me since I've moved to Windows7. If you're unfortunate to be stuck with Windows Vista still, I did discover that it only hung on right-click when waiting for the intellisense database to be built (see the bottom left corner for it's progress). The only "fix" I had was to wait for intellisense to stop building, then do a right-click.

like image 25
Mark Ingram Avatar answered Nov 09 '22 06:11

Mark Ingram


I wrote a piece of code the other day, a very crazy template, and the latest VisualStudio would just hang if I placed my mouse over the templated code. It was surreal :)

Anyways you might have an issue like that and you might want to delete your intellisense database and try again.

like image 40
Robert Gould Avatar answered Nov 09 '22 06:11

Robert Gould


Try launching Visual Studio in safe mode to rule out problems with any extension installed.

like image 2
VVS Avatar answered Nov 09 '22 06:11

VVS