0

How to open firefox "open menu" using keyboard shortcut? I am unable to find the keyboard shortcut on google. I want to automate the process using selenium as I want to open an installed add on.

enter image description here

Harsh Nigam
  • 465
  • 2
  • 6
  • 22

2 Answers2

0

For an automation task like this you maybe using the wrong technology.

Have you tried using AutoIt for a task like this? Then switching back to Selenium when you need to interact with the DOM?

Jamie Rees
  • 7,973
  • 2
  • 45
  • 83
  • okay...i was thinking if i can use the keyboard shortcuts..as there are number of selenium commands to execute key based operations. I will try autoit as well. will update. – Harsh Nigam Apr 30 '15 at 08:29
  • @Harsh Correct, you can use the Selenium `SendKeys();` method but that relies on the version of firefox you are using to have a Key function for every step you require to install a plugin. It doesn't seem the right tool for the job. – Jamie Rees Apr 30 '15 at 08:30
  • yeah..actually i was trying this code which i googled on stackoverflow..WebElement toClear = d1.findElementByXPath("html/body/form/div/div/div[2]/div[2]/div/div/div[1]/div[2]/div[1]/input"); toClear.sendKeys(Keys.CONTROL + "a"); toClear.sendKeys(Keys.DELETE); ..but let me try auto it also, i will update you..meanwhile if you get some info regarding this methodology and then do update me...thanks a lot! – Harsh Nigam Apr 30 '15 at 08:34
  • Hi Jamie..when I have used the autoit script in .exe format, i implemented selenium using the Runtime.getRuntime().exec("C:\\Users\\pcs\\Desktop\\TEST_x64.exe"); and also following version of .exe file Runtime.getRuntime().exec("C:\\Users\\pcs\\Desktop\\TEST.exe"); and I am getting following error : Jun 04, 2015 4:24:33 PM org.openqa.selenium.os.UnixProcess$SeleniumWatchDog destroyHarder INFO: Command failed to close cleanly. Destroying forcefully (v2). org.openqa.selenium.os.UnixProcess$SeleniumWatchDog@ – Harsh Nigam Jun 04 '15 at 10:58
  • Have you tried using the `System.Diagnostics.Process.Start()`? See this post:http://stackoverflow.com/questions/240171/launching-a-application-exe-from-c – Jamie Rees Jun 04 '15 at 11:02
0

You can reach some of the main menu's options via the hidden extended menu set which can be shown after pressing Alt when not in fullscreen mode.

elig
  • 2,635
  • 3
  • 14
  • 24