-1

How to click on Menu Bar>>Tools Menu of Mozilla Firefox using selenium Webdriver?

2 Answers2

0

You CAN'T do something like this. You just can handle the HTML elements, events and simulate actions between your HTML and the user. Selenium works with the DOM, is used to test your web application not to interact with the browser as OS an app.

ianaya89
  • 4,153
  • 3
  • 26
  • 34
0

You can use the following code:

 Robot robot = new Robot();
    robot.keyPress(KeyEvent.VK_CONTROL);
    robot.keyPress(KeyEvent.VK_L);
    robot.keyRelease(KeyEvent.VK_L);
    robot.keyRelease(KeyEvent.VK_CONTROL);
    
    robot.keyPress(KeyEvent.VK_TAB);
    robot.keyRelease(KeyEvent.VK_TAB);

    robot.keyPress(KeyEvent.VK_TAB);
    robot.keyRelease(KeyEvent.VK_TAB);

And then use the right arrow to move from one element to another.

Ledjon
  • 105
  • 8