# Mouse Click with Keypress

**URL:** <https://forum.kirupa.com/t/mouse-click-with-keypress/314474>\
**Category:** flash\
**Created:** [September 29, 2010, 5:36pm UTC](https://forum.kirupa.com/t/mouse-click-with-keypress/314474 "2010-09-29T17:36:28Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![griff\_kasier](https://avatars.discourse-cdn.com/v4/letter/g/df788c/32.png) [@griff\_kasier](https://forum.kirupa.com/u/griff_kasier)\
**Post date:** [September 29, 2010, 5:36pm UTC](https://forum.kirupa.com/t/mouse-click-with-keypress/314474/1 "2010-09-29T17:36:28Z")

</div>

While creating an application, I ran into a unique question. I did some research and understand KeyboardEvent and MouseEvent separately, but how would I code them to be dependent on each other?

For example:

Let’s say I have a button. When you click this button, a number in a dynamic textbox will increment. If you were to be holding Ctrl, however, the number would decrement.

Anyone have any ideas on this one?
