Save Visual Studio’s Configuration for a Rainy Day

Visual Studio is one of the best IDEs for C++ development. It has a good mix of  powerful tools  and ease of use.

One downside of VS is how easy it is to mess up the windows layout, and other environment settings.   Another downside is that it tends to happen  at the most inconvenient  times.

Saving the IDE layout when everything is  looking and working the way I like. Lets me do a quick reset to my preferred setup without having to google around for ways to restore a  MIA tab.

The procedure is easy and works the same for recent VS versions:

Select Tools –> Import And Export Settings

image

Select the Export radio button:

image

In the next window,  you can select which settings you want to export. I usually export the general settings only, but  shop around and see if  there is anything else you’d want to save.

image

(You can expand the General Settings to subcategories.  I found its easier  to save the whole tree, but you can  fine tune your  selection if it suits you)

The next windows ask you for a save location and file name. I suggest you select a location  that will survive a hard disk disaster, for example, a backed up network directory.  You can also  check the file into a source control repository as it is a plain  XML  file.

image

That’s it!   the next time Visual Studio change things under your feet  you can show it who’s the boss by importing the file  you just saved:

Select Tools –> Import Export Settings:

image

The next windows let you save your current (possibly messed up)  settings  before you override them.  Take the opportunity to do so.  it will take less than a second to delete this file if everything goes well.

image

In the next window browse for your file (or select it from the Recent Files list if its there )

image

The next screen asks you to confirm the import,  the list should contain  the settings you exported earlier :

image

Once the import is done,  your IDE should return to its old self.

Conclusion

It’s not  rocket science  but it does save time. Like anyone who used source control for any length of time know,  sometimes it’s much easier to revert to an older version  than trying to clean up a mess one menu option at a time.

Leave a Reply

Your email address will not be published. Required fields are marked *