初学Selenium遇上的问题
2024-09-05 19:44:23
1.IWebDriver driver = new InternetExplorerDriver();运行时报关于protecte model的错误
解决办法就是用如下代码设置IEDriverOpiton,并将IEDriverServer.exe放在IE的同级目录下 C:\Program Files (x86)\Internet Explorer
static void Main(string[] args)
{
InternetExplorerOptions ieO = new InternetExplorerOptions();
//set ingnore protected mode as True
ieO.IntroduceInstabilityByIgnoringProtectedModeSettings = true;
IWebDriver driver = new InternetExplorerDriver(@"C:\Program Files (x86)\Internet Explorer", ieO);
driver.Navigate().GoToUrl("http://www.cnblogs.com");
}
最新文章
- 构建ASP.NET MVC4+EF5+EasyUI+Unity2.x注入的后台管理系统(14)-EasyUI缺陷修复与扩展
- sublime
- Visual C++中的一些编程小技巧
- JQuery拖拽排序
- KMP算法的Next数组详解
- C++学习笔记2:关于开发
- lightoj 1020 (博弈)
- IOS开发效率之为Xcode添加常用的代码片段
- POJ3190 Stall Reservations 【贪婪】
- iOS开发 GET、POST请求方法:NSURLSession篇
- Cocos2d-x 的“HelloWorld” 深入分析
- SolrCloud的介绍
- Codeforces 765E. Tree Folding [dfs][树形dp]
- linux 3.10 串口注册
- foxit pdf强制页面视图所有情况都为'合适宽度'
- Centos6.5DRBD加载失败,系统更换yum源(国内163)
- [Treap][学习笔记]
- Java Spring Boot VS .NetCore (四)数据库操作 Spring Data JPA vs EFCore
- 4337: BJOI2015 树的同构
- python vtk 通过回调函数监测键盘”Up”键动作,每按一次方向上键,actor变换一种颜色