I'm looking for a quick way to type the Enter or Return key in Selenium.
Unfortunately, the form I'm trying to test (not my own code, so I can't modify) doesn't have a Submit button. When working with it manually, I just type Enter or Return. How can I do that with the Selenium type
command as there is no button to click?
Best Solution
The
import
statement is for Java. For other languages, it is maybe different. For example, in Python it isfrom selenium.webdriver.common.keys import Keys