> For the complete documentation index, see [llms.txt](https://cmonkeys.gitbook.io/cinput-reference-manual/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://cmonkeys.gitbook.io/cinput-reference-manual/script-reference/methods/iskeydefined.md).

# IsKeyDefined

*bool* **IsKeyDefined**(*string* **keyName**)\
*bool* **IsKeyDefined**(*int* **keyHash**)

## Parameters

**keyName**: The name of the key (`action`), as defined in [`SetKey()`](/cinput-reference-manual/script-reference/methods/setkey.md).\
**keyHash**: The hashcode of the name of the key (`action`), as defined in [`SetKey()`](/cinput-reference-manual/script-reference/methods/setkey.md).

## Returns

**bool**: Returns `true` if `keyName` or `keyHash` exists.

## Description

Use this to determine if a key exists by the name of `keyName` or the hashcode of `keyHash`.

Note that you will probably never need to use this method unless you are a developer making a separate script/plugin and you want to make it compatible with cInput.

## Example
