views:

1803

answers:

4

Every time I open a windows forms application in VS .NET it takes minutes to initialize the Toolbox. Is there a way I can tell VS to cache this toolbox somehow?

A: 

Opening the ToolBox the first time will certainly have a delay but it should only be the first time it occurs. If you are seeing repeated delays then it's likely one of the following.

  1. A Plugin : What plugins do you have installed? Try uninstalling them and opening the toolbar a few times. That will eliminate the plugins as a suspect
  2. A custom control: If you make custom controls they get added to the toolbox. It's feasible that this could be causing some performance issue (unlikely though). Try commenting out the functional code in the controls and see if that improves performance.
JaredPar
no custom controls, only plugin is VASsistX
SDD
@SDD, try disabling that plugin, restart VS and open the toolbox several times.
JaredPar
+8  A: 

Turn off AutoToolboxPopulate in Tools->Options->Windows Forms Designer->Tools.

m_oLogin
Forgot about that setting.
JaredPar
This is already set to false.
SDD
+1  A: 

The ToolBox has a nasty habit of collecting garbage. It was pretty bad in VS2005. But recently discovered that VS2008 suffers from it too. On Vista, navigate to c:\users\yourname\appdata\local\microsoft\visualstudio\9.0. There are some hidden files there. The toolbox_reset.tbd and toolboxindex_reset.tbd files seem to be backup files to get out real trouble, there to copy over the hidden toolbox.tbd and toolboxIndex.tbd files.

Take a look at the ProjectAssemblies folder.

Hans Passant
So what should we do with the toolbox*_reset.tbd files?
mafutrct
I updated my post. Backup files before you start overwriting them. I deleted stuff from ProjectAssemblies without noticing real problems but can't be sure it will work for you.
Hans Passant
A: 

Deleting the .TBD from visualstudio\9.0 worked for me but result in a popup TFS30330: Team Explorer cannot write the to the project list configuration file. Also the files were recreated during VisualStudio2008 initialization but the initializing toolbox... does not occur. The TFS30330 error occurs each time i launch VS2008. I then had to reset my Visual Studio settings. But in the end it was worth it - no more forced coffee break as one blogger apptly put it.

kjpowers2