There are two methods we use to send the key events:
sendKeys()
sendKeyEvent(int)
Every keyboard event is associated with an integer value and we have to pass the integer value in the method to perform the desired action.
Suppose if we have to press the Enter key from keyboard then we have pass the keyboard event value for enter key in the method and then the desired action will be performed. The key event value for enter key is 66
Eg: driver.sendKeyEvent(66);
0 Comment(s)