Charlie from Microsoft has made a post commenting on my last blog entry - writing an installer with the standard Setup Project in Visual Studio on the sandbox blog (http://blog.mediacentersandbox.com/UseTheRegistrationAPIWiX.aspx) - oh, and thanks Aaron Stebner for point this out on his blog at http://blogs.msdn.com/astebner/archive/2007/06/20/3439251.aspx
I more than half-expected a response like this, and I admit that I probably didn't emphasise the point enough.
I have provided this method of installing as an example, but it is not the recomended way of producing installers for Media Center applications.
I chose this method for three reasons...
A. It shows the user what REALLY happens when you call RegisterMCEApp.exe.
B. It allows me to give the users a working installer program without having to install another application to get the sample code to run.
C. While WiX is the FAR more flexible, powerful and useful tool, I'm not all that familliar with it yet (although I have played around with ORCA enough with my previous installers to understand that it's primarily an XML interface to the installer database), so I'm not going to give all that much advice on a topic I REALLY don't understand. I'll stick to a topic that I know a little - but only slightly more - about.
D. At least partly, because I knew it would provoke a response, and I was trying to highlight the fact that I believe that if a feature is going to provoke a response like "Please don't use this method", perhaps it shouldn't even appear in the SDK - or it should appear with very large warning labels (again, I haven't checked the latest SDK...maybe they HAVE put those warnings in!)
Anyway, if you ARE interested in using WiX (which you should if you plan on formally releasing your code), I'll take you on a quick walkthrough of making the XML file you'll need. If you followed the basics of the last stage, you'll find this one a breeze.
<
application title="TriviaCenter" id="{D0515079-4F80-4970-93D5-02F5CF736444}">
<
entrypoint id="{396E0EB3-BC22-4cb2-A6CB-954B5F7CF444}"
addin = "TriviaCenter.BaseAddin,TriviaCenter,Culture=Neutral,Version=0.0.1000.0,PublicKeyToken=aadbb711d5721433"
title = "TriviaCenter"
description = "A Trivia Game for your Media Center"
ImageUrl = ".\AppIcon.png">
<
category category="More Programs"/>
<
category category="Services\Games"/>
</
entrypoint>
</
application>
This is much clearer than the registry format, to be honest, and much more simple. Your application tag defines a new Media Center app. You simply give your app a name, and a GUID (Globally Unique IDentifier). You make GUID's with the GUIDGEN tool that is part of Visual Studio - go to 'Tools' and selecte 'Create GUID'.
Then you define an 'Entry Point', which is basically the 'button' that you will use to start your addin. For this, you will need a title, description, another GUID (NOT the one you used in the 'Application' object!) and the complete path to your .NET class.
For an example of building this full path to your class, please see the Stage 10 documentation.
Finally, you choose your categories. This specifies where you want the 'entry point' button to appear. In this case, we have chosen both the 'More Programs' list and the 'Games' list.
There you have it, a basic XML file that you can use to register your application with Media Center.
You can even make a post-build command to register your application - but since you really only ever need to register and unregister once, I've actually turned 'Register MCML Application' into an entry in my Tools menu. Check the screenshot below.

Oh, there is one other advantage of using this method during development. If you use RegisterMCEApp and an XML file, Media Center is notified of the change to it's programs list and the list updates without you having to restart Media Center. This is VERY handy when debugging, because you can get very sick of the Media Center start window.