title: Mouse movement in a webpage using Selenium Webdriver
body: <p>I'm a beginner in Selenium webdriver. I'm trying to automate an action in <a href="http://www.amazon.in/" rel="nofollow">this</a> website </p>
  
  <p>In the webpage, I want to move the cursor to <strong>"Shop by category"->"Mobiles&amp;tablets"->then click the link "Android Mobiles".</strong> But could not see the link Android phone clicked. </p>
  
  <p>Could you guide me here, thanks.</p>
  
  <p>Below is the code,</p>
  
  <pre><code>public static void main(String args[]){
      WebElement oEle1,oEle2;
      System.setProperty("webdriver.ie.driver","C:\\Users\\1003061\\Documents\\Automation testing\\selenium softwares\\IEDriverServer_Win32_2.53.0\\IEDriverServer.exe");
      WebDriver driver=new InternetExplorerDriver();
      driver.manage().window().maximize();
      driver.get("http://www.amazon.in/");
      driver.manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS);
  
      Actions oMouse=new Actions(driver);
      oEle1=driver.findElement(By.xpath("//*[contains(text(),'Category')]"));
      oMouse.moveToElement(oEle1).build().perform();
      driver.manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS);
      oEle2=driver.findElement(By.xpath("//*[@aria-label='Mobiles &amp; Tablets']/span[contains(text(),'Mobiles &amp; Tablets')]"));
      oMouse.moveToElement(oEle2).build().perform();
      driver.manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS);
      driver.findElement(By.xpath("//a[contains(@href,'android_mobiles')]")).click();
  
  }
  </code></pre>