

- #Workspace manager visual studio extension zip file
- #Workspace manager visual studio extension update
- #Workspace manager visual studio extension code
IVsSolution solution = Package.GetGlobalService(typeof(SVsSolution)) as IVsSolution The SolutionEventsListener uses the very useful Package.GetGlobalService to get hold of the solution. Elisha has a simple listener wrapper as an answer on StackOverflow that I modified. I started with the IVsSolutionsEvents interface that includes OnBefore, OnAfter and OnQuery for basically everything. Next, I wanted to listen to events from the Solution like the unloading and loading of Projects.

I can have my package automatically load in situations like these:
#Workspace manager visual studio extension code
A number of blogs posts say you need to hard code a GUID like this, but they are mistaken. You can add one or more ProvideAutoLoad attributes to a Package class from the VSConstants class. I need to decide when my package is going to get loaded. I also setup the name, version and description in this file. VSIXs other than templates aren't supported in Express (I keep pushing, though): I want my VSIX package to work on Visual Studio 11 Beta as well as Visual Studio 2010 so I added to the SupportedProducts node like this. A VSIX has a manifest (which his just XML - isn't everything?) that you can edit in a GUI or as a text file.

#Workspace manager visual studio extension zip file
This builds into a VSIX (which is just a ZIP file - isn't everything?). I have Visual Studio 2010 SP1 so I needed the updated Visual Studio 2010 SP1 SDK. I downloaded the Visual Studio 2010 SDK after reading this blog on extending Visual Studio 2010. I had no need for buttons or menus, I just wanted to listen to events and act on them. I wanted to create an add-in with Zero UI. You can add menus, add tool bars, commands, new templates, new kinds of designers and visualizers, as well as use just the shell to create your own IDE. There's a number of different kinds of things you can extend. It's gotten a lot better with Visual Studio 2010 but back in the 2003-2005 days it was really hairy. Creating a Visual Studio Extensionĭeveloping Visual Studio Extensions requires some patience. Plus, it works on my machine so you've got that going for you. It only listens to two events and it's only 12k so you have no reason that I know of to be afraid of it. Warranty: To be clear this is the smallest of extensions. It'd be a good chance to write my first Visual Studio Add-In, see if this is even possible, and fix an irritant at the same time.ĭOWNLOAD: Workspace Reloader Visual Studio Add-in - "This package will reload the code files you had open when your project file was modified and unloaded then reloaded" I've reported it as a bug and it's also been voted up at User Voice, visited as a Question at StackOverflow, and a few folks have tweeted about it (The SO guys with their thumbs on the scale, no doubt) and been bugging some folks but then I got the idea to just fix it myself. But when you open a project then right click and "Unload Project" you'll lose all your windows. Visual Studio saves all your open files and window positions when you close the IDE and restores them when you open your solution. It's a weird Visual Studio behavior that I've never understood.
#Workspace manager visual studio extension update
They'll be deep into something, update their project to test it and all their open windows close. Since they use distributed source control and often have a dozen or more folks all coding inside the same project they are integrating all the time.

This apparently is becoming kind of an issue at Stack Overflow. A while back my buddy Sam Saffron (from Stack Overflow and Mini Profiler) complained to me on Skype that he was finding it very irritating that every time he updated his project outside of Visual Studio he would be prompted to "Reload Project" and would lose all his open files because Visual Studio would close them.
