Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/csharp/292.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C# 硒和碳的概念_C#_Selenium_Selenium Rc - Fatal编程技术网

C# 硒和碳的概念

C# 硒和碳的概念,c#,selenium,selenium-rc,C#,Selenium,Selenium Rc,我是c-sharp的新手。我被要求检索c#中html中的selenium命令。我的意思是如果我们输入用户名为 用户名:testUser 我们以同样的方式进入 command=type target = xpath="/html..blah blah" value= testUser 现在我在我的C#中获得了这些信息,因为我使用了C#和HTML解析。现在我想以switch的形式执行它 switch(command) { case "type": selenium.T

我是c-sharp的新手。我被要求检索c#中html中的selenium命令。我的意思是如果我们输入用户名为 用户名:testUser 我们以同样的方式进入

command=type
target = xpath="/html..blah blah"
value= testUser
现在我在我的C#中获得了这些信息,因为我使用了C#和HTML解析。现在我想以switch的形式执行它

switch(command)
{
  case "type":
             selenium.Type(target,value);
              break;
            // and so on..
    case "click":
         ...........
         break;



 }
那么在这里,我需要委托或一些C#的概念来动态执行命令吗? 请回复。我是c#的新手。 我希望我的问题是清楚的。

您可以使用,它为您完成所有工作,并且您可以使用Selenium IDE自动生成测试类。

使用C#和Selenium,您可以在网页上执行操作,并通过检索文本值等来验证网页上的信息

关于如何使用C#设置selenium并创建基本脚本,您可以参考以下网页


您是否只需要在C#中导入selenium测试用例?我不清楚你在转换声明中问了什么