views:

245

answers:

0

.Net; EnvDTE; Visual Studio 2008;

I've written a simple console app. to create a new instance of Visual Studio 2008; followed by opening a solution into this instance (making use of the EnvDTE namespace). In Windows Task Manager devenv.exe loads in the background but the solution task a long time to load. Actually the solution is quite large with over a 100+ projects and so it does take a long time to open the solution in the normal way (eg double click sln file).

EnvDTE.DTE dte = (EnvDTE.DTE)System.Activator.CreateInstance(Type.GetTypeFromProgID("VisualStudio.DTE.9.0"));
dte.Solution.Open(@"c:\mysolution.sln");

Back to the console app - the app is designed to manipulate the solution and the projects in context of the solution; but there are no plans to manipulate the specific project items.

I'm making a guess here that the slow loading times is due to the VS loading in all the project items. Has anybody got some suggestions on some alternatives to manipulating solution/projects (but not text manipulation) or perhaps there's a way to speed up the loading times e.g. get DTE to not load the project items (lazy load??).

I don't have the option of splitting the solution into smaller solutions.

Many thanks :)