I am using Sikuli and my script returns an error because of the following line.
type("06/01/2017" + Key.ENTER)
On the screen, I see that the script types 06 and then it stops. The problem is the slash. The error seems to be related to me using a non-US keyboard. I found some tips online like using type("&") or type("7", KEY_SHIFT) instead. However, it does not work.
This is the error message I get:
type("06/01/2017"+Key.ENTER) at sun.awt.windows.WRobotPeer.keyPress(Native Method)
at java.awt.Robot.keyPress(Unknown Source)
at org.sikuli.script.RobotDesktop.doKeyPress(RobotDesktop.java:98)
at org.sikuli.script.RobotDesktop.doType(RobotDesktop.java:361)
at org.sikuli.script.RobotDesktop.typeChar(RobotDesktop.java:375)
at org.sikuli.script.Region.keyin(Region.java:4429)
at org.sikuli.script.Region.type(Region.java:4299)
at sun.reflect.GeneratedMethodAccessor29.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
java.lang.IllegalArgumentException: java.lang
.IllegalArgumentException: Invalid key code
Thank you in advance for any hints.
Try to use paste()
for entering the text and then type()
separately for pressing Enter.