https://bugs.winehq.org/show_bug.cgi?id=30353
Anastasius Focht focht@gmx.net changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |focht@gmx.net Summary|IEDriver from selenium |selenium |crash |'InternetExplorerDriver' | |fails to retrieve | |IHTMLDocument COM object | |reference as LRESULT
--- Comment #10 from Anastasius Focht focht@gmx.net --- Hello folks,
the instructions need to be updated ...
You obviously need to download the actual server binary to have 'webdriver.Ie()' instancing work. 'easy_install selenium' doesn't do that automatically for you.
Download: https://selenium-release.storage.googleapis.com/2.41/IEDriverServer_Win32_2.... (and put it into path visible in PATH).
I didn't see bug 30352 (wininet?) please retest.
The selenium driver basically does this:
http://www.moshkin.info/blog/accessing-web-browsers-window-contents-from-ano...
--- snip --- IHTMLDocument* IHTMLDocumentFromHWND(HWND hWnd) { UINT WM_HTML_GETOBJECT = RegisterWindowMessage(_T("WM_HTML_GETOBJECT")); if (WM_HTML_GETOBJECT == 0) return NULL;
DWORD lResult = 0; SendMessageTimeout( hWnd, WM_HTML_GETOBJECT, 0, 0, SMTO_ABORTIFHUNG, 1000, &lResult );
if (lResult == NULL) return NULL;
IHTMLDocument* HTMLDocument; HRESULT hr = ObjectFromLresult( lResult, IID_IHTMLDocument, 0, (void**)&HTMLDocument );
if (FAILED(hr)) return NULL;
return HTMLDocument; } --- snip ---
Relevant trace log:
--- snip --- ... 0037:Call user32.RegisterWindowMessageW(100e2a20 L"WM_HTML_GETOBJECT") ret=10092456 0037:Ret user32.RegisterWindowMessageW() retval=0000c042 ret=10092456 0037:Call KERNEL32.LoadLibraryW(100e2a44 L"OLEACC.DLL") ret=10092464 0037:Call PE DLL (proc=0x7dde7040,module=0x7dde0000 L"oleacc.dll",reason=PROCESS_ATTACH,res=(nil)) 0037:trace:oleacc:DllMain 0x7dde0000, 1, (nil) ... 0037:Ret KERNEL32.LoadLibraryW() retval=7dde0000 ret=10092464 ... 0037:Call user32.SendMessageTimeoutW(000200a4,0000c042,00000000,00000000,00000002,000003e8,014ad774) ret=10090fd9 ... 0039:Call user32.PeekMessageW(0033f35c,00000000,00000000,00000000,00000001) ret=6af030c7 0039:Call window proc 0xf697c886 (hwnd=0x200a4,msg="WM_HTML_GETOBJECT",wp=00000000,lp=00000000) 0039:Call user32.GetPropW(000200a4,f69a7308 L"THIS") ret=f697c8e9 0039:Ret user32.GetPropW() retval=0016e968 ret=f697c8e9 0039:Call user32.DefWindowProcW(000200a4,0000c042,00000000,00000000) ret=f697cb0f 0039:Ret user32.DefWindowProcW() retval=00000000 ret=f697cb0f 0039:Ret window proc 0xf697c886 (hwnd=0x200a4,msg="WM_HTML_GETOBJECT",wp=00000000,lp=00000000) retval=00000000 0039:Ret user32.PeekMessageW() retval=00000001 ret=6af030c7 ... 0039:Call user32.TranslateMessage(0033f35c) ret=69d80b8d 0039:Ret user32.TranslateMessage() retval=00000000 ret=69d80b8d 0039:Call user32.DispatchMessageW(0033f35c) ret=69d80b99 0037:Ret user32.SendMessageTimeoutW() retval=00000001 ret=10090fd9 0039:Call window proc 0x69d80a44 (hwnd=0x100a8,msg="nsAppShell:EventID",wp=00000000,lp=012d0998) 0037:Call KERNEL32.GetProcAddress(7dde0000,100e303c "ObjectFromLresult") ret=10090fe8 0039:Ret window proc 0x69d80a44 (hwnd=0x100a8,msg="nsAppShell:EventID",wp=00000000,lp=012d0998) retval=00000001 0039:Ret user32.DispatchMessageW() retval=00000001 ret=69d80b99 ... 0037:Call oleacc.ObjectFromLresult(00000000,100de1ec,00000000,014ad830) ret=10091000 0037:trace:oleacc:ObjectFromLresult 0 {332c4425-26cb-11d0-b483-00c04fd90119} 0 0x14ad830 0037:Call KERNEL32.GlobalGetAtomNameW(00000000,014ad5a2,00000027) ret=7dde5f4c 0037:Ret KERNEL32.GlobalGetAtomNameW() retval=00000000 ret=7dde5f4c 0037:Ret oleacc.ObjectFromLresult() retval=80004005 ret=10091000 --- snip ---
$ wine --version wine-1.7.17-175-gc1bf61e
Regards