To send hotkeys(shortcut keys) like ctrl + s to swing application

29 views
Skip to first unread message

Bharath

unread,
Dec 7, 2019, 1:53:54 PM12/7/19
to Marathon Java GUI Testing
Hi Team,

How to send hot keys like ctrl + s to swing application ? How to test any hot keys on swing application ?

I tried with below code and it is not working .


WebElement passwordTextBox = driver.findElement(By.id("password"));
        passwordTextBox.sendKeys(Keys.chord(Keys.SHIFT,"testpassword"));


or

Actions action = new Actions(driver);
    action.sendKeys(Keys.F5).build().perform();

Thanks,
Bharath

Aditya Chandrasekhar Karra

unread,
Dec 9, 2019, 10:38:32 AM12/9/19
to marathon...@googlegroups.com
Hi Bharath,

Thank you for using Marathon. 
You can use standard selenium Action class for passing the keys.
Please check this link which will help you.


Have a great day :)

Thanks & Regards
Aditya Karra
Jalian Systems Pvt. Ltd.

Jalian Systems Pvt. Ltd.
#457, 5th Main, 3rd Cross, 5th Block, 1st Stage, H B R Layout,
Bengaluru 560043, INDIA


--
Looking for professional help with your Marathon projects?
Go visit: http://marathontesting.com
---
You received this message because you are subscribed to the Google Groups "Marathon Java GUI Testing" group.
To unsubscribe from this group and stop receiving emails from it, send an email to marathon-testi...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/marathon-testing/ca1d9cb6-38f7-4ae7-a350-26b6547fded5%40googlegroups.com.

Bharath Kumar

unread,
Dec 9, 2019, 10:47:31 AM12/9/19
to marathon...@googlegroups.com
Ok thanks Aditya for your information.

Thanks
Bharath 

Reply all
Reply to author
Forward
0 new messages