Installing the Media Center SDK on a system with an un-activated VS Express Edition

I recently installed the refreshed version of the Windows Vista Media Center SDK on one of my Windows Vista system and ran into an installation issue that I wanted to describe here in case anyone else sees similar issues when installing the SDK on their systems. 

The root cause of the issue is that if you install any of the Visual Studio 2005 Express Editions from the web download links, they require you to perform a free registration within 30 days of installing them.

On the system where I saw this issue, I had the Visual C# 2005 Express Edition installed, but had not yet registered it.  Then, when Media Center SDK setup ran, it invoked the Visual C# Express Edition as a custom action in order to register the Media Center project templates and item templates within the Visual C# IDE.  Since my copy of Visual C# had been installed more than 30 days ago and had not yet been registered, when it was invoked during SDK setup, it popped up a dialog asking me to enter a registration code.  At the time I was installing the Media Center SDK, I was not connected to the internet, so I was not able to obtain a registration code.  Instead I just dismissed the dialog and made a mental note to register Visual C# Express the next time I was online.

Later on, I was connected to the internet, so I launched Visual C# Express and registered it.  Then, I attempted to create a new Media Center project.  However, when I opened the New Project dialog, I did not see any available project templates for Media Center projects.

After looking into this scenario in more detail, I realized that the custom action to register the Media Center project templates had not executed correctly because I dismissed the registration dialog that popped up during SDK setup.  I was able to fix my system by going to the Add/Remove Programs control panel (also known as Programs and Features on Windows Vista) and repairing the Media Center SDK.

If you run into a similar issue where you do not see Media Center project templates in the Visual Studio New Project dialog in Visual C# Express or Visual Basic Express after installing the SDK, I suggest making sure that your Visual Studio Express Edition has been registered, and then repair the Media Center SDK.

Note also that this same issue could affect any setup that installs project templates, item templates or add-ins for use in Visual Studio, so repairing your Visual Studio add-in might be helpful.