Which state I can invoke interface methods safely in BHO?
-
sabato 21 aprile 2012 14:10
I want to develop a tool for Web Automation test.
I write a BHO for obtaining the attributes of an element. such as text, position and so on.
but it sometimes cores dump when invoking some methods, for example, IHTMLElement->get_parentElement
if IWebBrowser2->Busy is VARIANT_FALSE and IHTMLDocument->readyState is complete, the dump never happens.
but it seems the verification is too strict. sometimes, some of web pages keep interactive state and the page seems normal. the operation will be blocked.
so how to call methods safely? is there any better ways?
- Modificato spyinsky sabato 21 aprile 2012 14:11
Tutte le risposte
-
lunedì 23 aprile 2012 11:06Did you try to debug your tool, so that the cores dump
NEU_ShieldEdge
-
martedì 24 aprile 2012 02:31
yes. I debug.
dump happens when invoking some methods of the HTML object. but the object seems normal. only in different state.
- Modificato spyinsky martedì 24 aprile 2012 02:32
-
giovedì 3 maggio 2012 16:13
I get some IHTMLElement objects and put them in the list.
then the page may refresh or load another page.
so the control does not exist but IHTMLElement objects in list still exist, not released.
when invoking their method, sometimes, it cores dump.
- Modificato spyinsky giovedì 3 maggio 2012 16:21

