In some projects, but not all, when I open a designer for the first time (either WinForms or typed dataset) Visual Studio thrashes the disk for up to 30 minutes while freezing (this appears to be reads and writes with between 100 and 140 pages\sec).
Once it has done it the first time for a project, it’s fine opening other projects until I close and re-open VS where it will freeze/thrash again the first time I open a designer.
Does anyone else see this, what the hell is it doing, and is there anything I can do to stop it?
OK, so it looks like it was defunct database connections in the Server Explorer tab:
A database on our test server was removed without my knowledge, but my project still had a data connection set up for it. It seems that whenever a table adapter is initialised in the designer, VS tries to connect to all the databases in the data connections list causing issues if the database does not exist. It even tries to connect to data connections that are not used by the current table adapter.
Some of our WinForms were badly written (naughy devs!) and were loading data in the constructors without checking for ‘DesignMode’ – these have been repaired.
Herbie