Title: XPCOM component not being registered by regxpcom

Hi,
I've built an XPCOM component that uses the nsIContentPolicy interface. The nsIContentPolicy function I'm using is ShouldLoad (gets called just before a new page is rendered). I register my XPCOM component using regxpcom as instructed in "Creating XPCOM Components", but for some reason it doesn't seem to be working. In fact even though regxpcom says that it's registered successfully I'm not sure it is. When I use Component Viewer in Mozilla my component doesn't appear in the list of registered components. Anyone got any ideas why it doesn't appear? I use regxpcom as follows; regxpcom -x "C:\gecko-sdk\bin" "C:\Program Files\Common Files\mozilla.org\GRE\1.7.6_2005031907\components\TestPageLoad.dll"

Am I putting my dll in the right place?

If I take a look at compreg.dat I can see it's been updated with details of my component and the interfaces  being used by my component. xpti.dat is also touched but it doesn't seem to have been updated in any way (as far as I can tell). So as I say my code doesn't seem to be getting called when Mozilla starts and and I can't see my component in component viewer.

Also, should have mentioned that my component is registered as an xpcom-startup observer so that it gets loaded when XPCOM is loaded (done this using the sample code in "Creating XPCOM Components").

Any help greatly appreciated.

Thanks,
 Damo

Reply via email to