# Keypress in other application

**URL:** https://discourse.processing.org/t/keypress-in-other-application/30783
**Category:** Coding Questions
**Created:** [June 18, 2021, 9:31pm UTC](https://discourse.processing.org/t/keypress-in-other-application/30783 "2021-06-18T21:31:01Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![MoonAlien822](https://avatars.discourse-cdn.com/v4/letter/m/65b543/32.png) [@MoonAlien822](https://discourse.processing.org/u/MoonAlien822)
#### Post date: [June 18, 2021, 9:31pm UTC](https://discourse.processing.org/t/keypress-in-other-application/30783/1 "2021-06-18T21:31:01Z")

</div>

Is there any way to have a program press a key in another application?

---

<div class="post-metadata">

### Author: ![th75](https://avatars.discourse-cdn.com/v4/letter/t/ebca7d/32.png) [@th75](https://discourse.processing.org/u/th75)
#### Post date: [June 18, 2021, 10:50pm UTC](https://discourse.processing.org/t/keypress-in-other-application/30783/2 "2021-06-18T22:50:03Z")

</div>

hi,

you can try with [java.awt.Robot](https://stackoverflow.com/questions/2482062/can-a-java-program-type-into-another-windows-program-like-notepad/2549184#2549184)  
(here is a pure java sample, it needs to be adapted…)

i use [SikuliX](http://sikulix.com), it needs to be installed , but it simplify some more complex stuff (eg, you give a picture and it find it s coordinates on the screen to click or do some OCR…
