当你的selenium WebDriver 启动IE11报这个错时:Unable to find element on closed window (WARNING: The server did not provide any stacktrace information),通过Google解决了:
Required Configuration:
For IE 11 only, you will need to set a registry entry on the target computer so that the driver can maintain a connection to the instance of Internet Explorer it creates. For 32-bit Windows installations, the key you must examine in the registry editor isHKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_BFCACHE. For 64-bit Windows installations, the key isHKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_BFCACHE. Please note that the FEATURE_BFCACHE subkey may or may not be present, and should be created if it is not present. Important: Inside this key, create a DWORD value named iexplore.exe with the value of 0.
Unable to find element on closed window (WARNING: The server did not provide any stacktrace informat
最新推荐文章于 2023-09-07 20:35:10 发布
本文解决Selenium WebDriver在启动IE11时遇到的Unable to find element on closed window错误。通过设置注册表项FEATURE_BFCACHE,确保WebDriver能与创建的IE实例保持连接。适用于32位和64位Windows安装。
2万+

被折叠的 条评论
为什么被折叠?



