Send Keys

May be its works : WebUI.sendKeys(findTestObject(null)

import org.openqa.selenium.By
import org.openqa.selenium.Keys
import com.kms.katalon.core.webui.driver.DriverFactory


Forgot to reply back. This was the method I tried and it worked. Great minds! Thanks again

1 Like

SendKeys adds me an ASCII Null in the end of string or instead of Enter or other commands. Any ideas?

Thanks in advance!


Update: Tried both on Chrome and Firefox, in Manual and Skript modes. The same output.That weird symbol is still there:

Update: It finally works perfectly on Chrome. Any ideas, what can be changed in Firefox confs?

I was able to get this to work and did not see a NULL at the end of the command.

WebUI.sendKeys(findTestObject(‘RepositoryItem’), Keys.chord(Keys.ENTER))
For the input, Choose a Value Type “Keys”. The value will default to ENTER but if you dropdown the VALUE menu, other key options will be displayed.

Hope this helps!

1 Like

The same result… What browser do you use?

We’re using Chrome and Firefox. Latest and greatest. You could take the body element and assign it to a repository item. Have you tried this?

No, can you please give me more details, how to do that?

Create new Test Object with “/html/body” as the xpath. Use this test object as the element that will receive the Send Keys.

Don’t get, how could it help me…

Is there a reason for why you are attempting to intput a string using send keys? Why not just use set text

Tried it as well, and it works fine. However I need to manipulate with pop-up menu later, which can’t be accessed without using Keys.ENTER and Keys.ARROW_DOWN

Here happens the same in Firefox. In Chrome this works perfectly

This doesn’t work for me, do you know if it have another way to send keys without pass object?

working fine on Chrome but having issues while executing same in firefox. please help

1 Like


I am facing issue while working with sendkeys keyword:

WebUI.sendKeys(findTestObject(<>), Keys.chord(Keys.ENTER, Keys.CONTROL))

while running this statement, I am getting below error:

com.kms.katalon.core.exception.StepFailedException: Unable to send keys ‘’ to object

Are you using firefox?

If yes, can you try on google chrome browser?

I am using Chrome Browser only.

This is a known issue, and I have a feature request out there to fix it:

Kindly upvote this to give it some attention.

In the meantime, you should use pure selenium to do it. Please check this post for a workaround:

1 Like

How to Send Keys Ctrl + N to open a new tab from the current window.

Steps to be followed :
Log in to the application
Open new tab - ?
Navigate to URL

Kindly share your inputs and my code is as follows :


WebUI.navigateToUrl(GlobalVariable.baseurl)‘Login Application/Login_Btn’))

WebUI.sendKeys(findTestObject(‘Login Application/userName’), GlobalVariable.username)

WebUI.sendKeys(findTestObject(‘Login Application/passWord’), GlobalVariable.passwd)‘Login Application/SignInbtn’))

'Press Ctrl+N to open new tab apps button ’
not_run: WebUI.sendKeys(findTestObject(‘Login Application/Apps button’), Keys.chord(Keys.CONTROL, ‘n’))

not_run: WebUI.sendKeys(Keys.chord(Keys.CONTROL, ‘n’))