Question

I have a working code that is working on IE6,7,8 & 9 Beta but crashes on IE9 RC. I can see that the web page is using the ActiveX's interface successfully but when I try to call IDispatch::Invoke from the ActiveX , the ActiveX crashes.

My application is constructed from a CHtmlView (IE container) a web page (GUI) and an ActiveX (the application itself), I see that the webpage uses the ActiveX's interface successfully but when I try sending data back to the webpage I crash.

After debugging the code (vs2005 c++) I found that all IDispatch functions cause a crash, but this behavior only reproduce with the RC version, our product is already running for a bout 3 years without a problem and now every client that upgrades to the RC cannot use our product anymore.

Were there any changes that can cause such a behavior? according to the documentations on-line I couldn't find anything. Thanks.

Was it helpful?

Solution 2

After tiresome struggle I found the answer (2 years ago). Back then I closed the questions on the IE9 forum but I forgot to close this thread.

Thank you @Paul Sweatte for reminding me.

Our framework worked as followed:

  1. The activex and the web had a set of known strings such as: "onStart" , "onPause" etc...
  2. The web would register the function in the engine.
  3. The activex would call the callback when needed

The second part was the problem, apparently in old IE versions, the javascript eval function would create IDispatch objects, and you could pass the objects to the activex.

In IE9 along with many other changes this changed too, and eval would return something else.

The crush would happen when the activex tried to execute the callback. It was ... VERY hard to debug.

OTHER TIPS

IE9RC introduced ActiveX Filtering:

Internet Explorer 9 RC allows you to block ActiveX controls for all sites, and then turn them back on for only the sites that you trust with the new ActiveX Filtering option.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top