[EMAIL PROTECTED] wrote:

> I have created an XPCOM Component which listens to the xpcom-startup
> and xpcom-shutdown events. Jus now I am copying MyComponent.dll to ..
> \component folder and deleting compreg.dat file from profile folder.
> So next time when mozilla starts up it registers the compnent ( I have
> user ComponentRegistrationProc in GetNSModule). So it register on it's
> own.
> 
>  I don't want to delete compreg.dat file manually. So I want to
> autoregister my component.I am trying to use
> NsComponentRegistar::autoRegister to force the registration itself. I
> doubt is it the proper way.But I don't know from where to call that
> method??

I think you need to back up and explain why you're putting a component into
the Firefox components/ directory in the first place. This is not
recommended: you should ship the component in an extension and either

* have the user install the extension
* register the extension for global use in the Windows registry [1]
* unpack the extension into the Firefox extensions directory (not recommended!)

In any of these cases, when Firefox first detects the new extension it will
automatically properly register components contained in it.

--BDS

1.
http://developer.mozilla.org/en/docs/Adding_Extensions_using_the_Windows_Registry
_______________________________________________
dev-tech-xpcom mailing list
[email protected]
https://lists.mozilla.org/listinfo/dev-tech-xpcom

Reply via email to