How to fix corrupted project and item templates in Visual Studio?

While working on an ASP.Net application on Visual Studio 2008, I ran into a problem. When I right clicked on the project to add a new page into the project, i got the error message that no templates could be found. Well, that was kind of strange that I was working on the project night before and I did not run into such problems. Recently Microsoft has become pretty good about their error reporting providing some initial hints. In this case the message said that I should look in the event logs to find more details. The event logs had the following error message.

The global template information is out of date. Regenerate the templates by running 'devenv.exe /installvstemplates' or reinstalling the application. Note: corrective action requires Administrator privileges.

In the past I would have took the option of reinstalling Visual Studio. But this time the error message provided an alternative to fix the issue by reinstalling templates by running a command line option. And it worked. After I ran the command, Visual Studio 2008 was back to its normal templates.

comments powered by Disqus




20.7 °C / 69.2 °F

weather conditions Clouds

Monthly Posts

Blog Tags