MozNET Tutorial - Register A Custom Component : AIO Specific
This short tutorial will describe the steps you need to follow in order to register and unregister XPCom components with the AIO component. It's a very simple process and I'll have you up and running with the ball in no time.A Good Text Editor
First thing first. We need a decent, light-weight, text editor. While Visual Studio is great for working with code files it's a bit overkill for what we're doing here. A good editor to use would be something such as Programmer's Notepad orNodepad++ or something similar. I use Programmer's Notepad, myself. It's free, light-weight, and has quite a few features. I'm sure you have you're own preference for text editors so feel free to use your favorite.A Simple Configuration
Let's get started...
To register your components with the MozNET AIO component you need a configuration file to tell MozNET what you want to do. All you need is a text file that has the extension of
xcg. That's it. Simple, eh?
Oh, yeah. You're probably wondering what to put in that file, eh? That's simple enough, too.
Here's a very easy example of a proper config file:
Not a whole lot to it, eh? All you need to do is place your configuration file into a subfolder of your output/install/bin directory and put all the component files that you want registered or upgraded into the folder with it. You're done. MozNET will find the file and do the work. Just as a note, a good file name for this configuration file is '
moz.cfg'.This allows your application to update its components with a simple restart.