I need to automate the action of hitting 'Enter' key on keyboard after entering a text in a text field.
I tried @browser.send_keys :enter
but that does not do the action. also have tried @browser.text_field(:name => 'q').send_keys :enter
or @browser.text_field(:name => 'q').focus
and then send_keys. But has not helped.
@browser.send_keys("{ENTER}")
does not help this too, this actually types ("{ENTER}")
Please let me know other ways of doing?
browser.send_keys :enter
should do the job. Please provide link to the page, link to a similar page, or relevant HTML.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With