

![Parralels](https://www.parallels.com/static/pl/fileadmin/res/img/navigation/pl-logo-dk.png)

# AppserverClient Command Line Interface

## sendkeys

sends keys to an active session.

**Category: Sessions**


```
AppServerClientCLI sendkeys -id rdp:5 -keys "abc<enter>123<enter>" [-wait 5000] [-delay 200]
```
* **` id (mandatory) `** Specify the ID of the session to where the key inputs are sent.
* **` keys (mandatory) `** Input the keys which are sent to the session.
* **` wait (optional) `** Wait for the specified number of milliseconds before sending keys.
* **` delay (optional) `** Delay each keystroke with the specified number of milliseconds.
## Return codes:
  ok
  NotAvailable
  InvalidId
  InvalidArgs
  InvalidState
  Exception
## Examples:
  AppServerClientCLI sendkeys -id rdp:5 -keys <ctrlaltdel>
  AppServerClientCLI sendkeys -id session:55435 -keys ABC<enter>123<enter>
## Notes:
  Can be used with RDP connections or a session from both RAS or RDP connection.
  Can send the following keys:
   0-9, a-z, A-Z, f1-f24, space character, and symbol characters like !^#.
  The keyboard layout of the local computer needs to match the remote session.
  Can send the following special keys enclosed in <>:
   ENTER, CTRL+ALT+DEL, BACKSPACE, TAB, HOME, PGUP, PGDOWN, END, LEFT, RIGHT, UP, DOWN, ESCAPE, DELETE, ALT+F4 
  Can send the CTRL+ALT to toggle the state of these keys.
   Wait is the time waited, in milliseconds, before the keys are sent.
   Delay is in milliseconds and is per keystroke.
## See also:
[getsessionsinfo](getsessionsinfo.md)
[disconnectsession](disconnectsession.md)
[uploadfile](uploadfile.md)
[downloadfile](downloadfile.md)
