我应该在哪里放置我的chromedriver文件?(Where should I place my chromedriver file?)
我正在使用Ubuntu 14.04。 我
home/user/project
有一个Rails应用程序“项目”。 我想将ChromeDriver与SeleniumWebdriver一起使用。 我下载了ChromeDriver可执行文件,但Selenium无法找到该文件。 它给了我这个错误:Selenium::WebDriver::Error::WebDriverError: Unable to find the chromedriver executable. Please download the server from http://chromedriver.storage.googleapis.com/index.html and place it somewhere on your PATH
我花了一个多小时阅读关于PATH和环境变量的文章/问题,他们一直在谈论编辑像〜/ .profile和〜/ .bashrc和〜/ .pam_environment这样的文件,但是我可以告诉我的电脑没有甚至没有任何这些文件。
是不是只有一些文件夹,我可以放置ChromeDriver可执行文件,以便Selenium可以找到它?
I'm using Ubuntu 14.04. I have a Rails app "project" located at
home/user/project
. I want to use ChromeDriver with SeleniumWebdriver. I downloaded the ChromeDriver executable, but Selenium can't find the file. It gives me this error:Selenium::WebDriver::Error::WebDriverError: Unable to find the chromedriver executable. Please download the server from http://chromedriver.storage.googleapis.com/index.html and place it somewhere on your PATH
I've spent upwards of an hour reading articles/questions about PATH and environmental variables, and they keep talking about editing files like ~/.profile and ~/.bashrc and ~/.pam_environment, but from what I can tell my computer doesn't even have any of those files.
Isn't there just some folder where I can place the ChromeDriver executable so that Selenium can find it?
原文:https://stackoverflow.com/questions/35353233
最满意答案
感谢Novemberland,这非常有效,只需忘记End IF这是完整的解决方案。
Imports System.Globalization Friend Overrides Function Filter() As String Dim sb As New StringBuilder() If (myCal.GetDayOfWeek(app.IncomeNext).equals("Saturday") or myCal.GetDayOfWeek(app.IncomeNext).equals("Sunday")) Then sb.Append("No weekends supported;") End If Return sb.ToString() End Function
Thanks Novemberland, that worked great , just forget the End IF Here is the full solution.
Imports System.Globalization Friend Overrides Function Filter() As String Dim sb As New StringBuilder() If (myCal.GetDayOfWeek(app.IncomeNext).equals("Saturday") or myCal.GetDayOfWeek(app.IncomeNext).equals("Sunday")) Then sb.Append("No weekends supported;") End If Return sb.ToString() End Function
相关问答
更多-
vb.net发布过滤器(vb.net Post Filter)[2023-09-30]
感谢Novemberland,这非常有效,只需忘记End IF这是完整的解决方案。 Imports System.Globalization Friend Overrides Function Filter() As String Dim sb As New StringBuilder() If (myCal.GetDayOfWeek(app.IncomeNext).equals("Saturday") or myCal.GetDayOfWeek(app.IncomeNext).equals(" ... -
接受发布数据VB.net(Accept post data VB.net)[2021-10-20]
您不需要,ASP.NET会为您执行此操作,并通过Request.Form集合提供数据,其中的项目由key索引。 上传的文件通过Request.Files而不是Request.Form公开。 String value1 = Request.Form["value1"]; HttpPostedFile image = Request.Files["value2"]; For the picture: Dim pix As HttpPostedFile = System.Web.HttpContext.Curr ... -
这是一个选项,您只对选中的项目感兴趣。 Public Function buildWhereClause() As String Dim query As String = "select * from products" Dim joiner As String = " " Dim condition As String = String.Empty Dim priceCondition As String = String.Empty ...
-
你要么更新你的series或clear and add ,否则系列将被复制。 SQL.ExecQuery("SELECT Date= DATEPART(DAY,Date), SUM (Amount) AS Amount FROM Sales WHERE Date = '" + Me.calender.Value.ToString() + "' GROUP BY DATEPART(DAY, Date) ") Chart1.DataSource = SQL.SQLDS.Tables(0) ' You ne ...
-
我找到了解决问题的方法。 我需要使用数据视图而不是数据集来更改,排序和过滤我的数据。 我的bindgrid函数变成了这样: Private Sub BindGrid() Dim ds As New DataSet ds.ReadXml(Server.MapPath("~/Event_Info.xml")) Dim myView As New DataView myView = ds.Tables(0).DefaultView ...
-
我想出了这个答案......我改变了我的路线.rb到此 Rails.application.routes.draw do get 'timerecords/index' get 'employees/index' get 'employees/show' get 'employees/new' get 'welcome/index' root :to => 'employees#new' post '/update_info' resources :em ...
-
根据我上面的评论,问题可能是你在过滤器中包含的内容比在字段中多(或少)。 如果该字段仅包含10:25 AM并且您的过滤器包含日期(因此您的完整过滤字符串是30-Dec-99 10:25 AM ),这将返回无匹配或如果该字段实际包含秒和时间你不会得到一个匹配。 (无论是哪种情况,如上所述格式化,它只会显示10:25 AM 。 如果您的字段仅包含10:25 AM的时间,请尝试: PaymentdetailsBindingSource.Filter = "log_in_time = '" & LoginTime. ...
-
Imports Excel = Microsoft.Office.Interop.Excel Public Class Form1 Private Sub Button1_Click(ByVal sender As System.Object, _ ByVal e As System.EventArgs) Handles Button1.Click Dim xlApp As Excel.Application Dim xlWorkBook As Excel.Workbook D ...
-
我不认为你可以直接在binding source上设置一个忽略连字符(如第一个查询中)的过滤器。 过滤器表达式列中没有可能的字符串操作。 从这个http://msdn.microsoft.com/fr-fr/library/system.windows.forms.bindingsource.filter.aspx中 ,唯一允许的字符串操作是+ 。 但是,您可以保留并显示包含连字符的原始列,并添加另一个不显示的列(不带连字符),但只用于过滤。 使用MSSQL ,您可以添加使用REPLACE函数的计算列 。 ...
-
您似乎遇到两个问题:匿名类型和lambdas - 下面的转换应该澄清这些问题:Option Infer On Dim personName As String = txtPersonName.Text Dim personAge As Integer = Convert.ToInt32(txtAge.Text) Dim opportunites = From p In Me.DataContext.Persons Select New With { Key p.PersonID, ...