Hi, does someone know
how to place the mousecursor somewhere on the screen?
I want to do something like
setMousePosition(500,300);
so that the cursor appears there.
Hi, does someone know
how to place the mousecursor somewhere on the screen?
I want to do something like
setMousePosition(500,300);
so that the cursor appears there.
you can do this using the java.awt.Robot class, particularly using the method mouseMove(int x, int y), try google for some full source code examples.
Ok, I found it already.
If someone else also wants to know:
Use the class Robot.java from awt:
Robot robot = new Robot();
robot.mouseMove(200,300);
you need to catch an awt-Exception when creating the robot.
That´s all.