I am trying to call a BHO object method from a javascript function (javascript is injected by BHO using IHTMLWindow2 execScript).
function foo() { IEBHO.DoSomething(); }
IEBHO is a BHO object and is already loaded in IE9.
And the DoSomething interface / method is declared in the BHO project IDL file as follows:
[id(1), helpstring("method DoSomething")] HRESULT DoSomething();
This approach works fine with IE7 and IE8. The DoSomething method / interface is successfully called from a javascript function.
However, in IE9, it seems to fail. It seems that javascript could not find the IEBHO object in its namespace, which causes the DoSomething method to fail.
I even used the IE7 / IE8 document mode inside IE9, and they all work fine, but once it is set to IE9 document mode by default, it fails.
Is this a bug in IE9? or is there a new way to access the BHO method?
Please, help...
Yours faithfully,
Franc
javascript internet-explorer-9 bho
Frank
source share