# Perspective Table onRowClick AND onKeyDown

**URL:** <https://forum.inductiveautomation.com/t/perspective-table-onrowclick-and-onkeydown/42450>\
**Category:** Ignition Early Access\
**Tags:** ignition80, perspective\
**Created:** [January 20, 2021, 6:53pm UTC](https://forum.inductiveautomation.com/t/perspective-table-onrowclick-and-onkeydown/42450 "2021-01-20T18:53:06Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![danieltalbot](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/danieltalbot/32/11201_2.png) [@danieltalbot](https://forum.inductiveautomation.com/u/danieltalbot)\
**Post date:** [January 20, 2021, 6:53pm UTC](https://forum.inductiveautomation.com/t/perspective-table-onrowclick-and-onkeydown/42450/1 "2021-01-20T18:53:06Z")

</div>

Anyone know of a way to detect if a key is being held down when clicking a table row? I want to perform different actions based on whether the row was clicked with the ctrl button held down or not.

---

<div class="post-metadata">

**Author:** ![cmallonee](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/cmallonee/32/6416_2.png) [@cmallonee](https://forum.inductiveautomation.com/u/cmallonee)\
**Post date:** [January 20, 2021, 7:08pm UTC](https://forum.inductiveautomation.com/t/perspective-table-onrowclick-and-onkeydown/42450/2 "2021-01-20T19:08:08Z")

</div>

Not directly within the context of the Event, but you could configure a separate `OnKeyDown` Event to write to a custom property, and then reference that custom property within the `onRowClick` Event.

```auto
if self.custom.ctrlKeyIsHeld:
    # do something

```

Just make sure that you include an appropriate `onKeyUp` Event to “reset” the custom property.

---

<div class="post-metadata">

**Author:** ![danieltalbot](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/danieltalbot/32/11201_2.png) [@danieltalbot](https://forum.inductiveautomation.com/u/danieltalbot)\
**Post date:** [January 20, 2021, 8:58pm UTC](https://forum.inductiveautomation.com/t/perspective-table-onrowclick-and-onkeydown/42450/3 "2021-01-20T20:58:32Z")

</div>

I like that! Thank you.

---

<div class="post-metadata">

**Author:** ![eric.petke](https://avatars.discourse-cdn.com/v4/letter/e/7feea3/32.png) [@eric.petke](https://forum.inductiveautomation.com/u/eric.petke)\
**Post date:** [October 16, 2024, 8:34am UTC](https://forum.inductiveautomation.com/t/perspective-table-onrowclick-and-onkeydown/42450/4 "2024-10-16T08:34:52Z")

</div>

Hi. Is this still working on version 8.1.39 (b2024040909)? i couldn't manage to get **neither** the onKeyDown nor the onKeyUp triggered.  
They **seems to be triggered only when editing a cell value** ; Not quit helpfull for the scenario.  
For me, information if keys like **ctrl, shift ,Alt** were hold when clicking or not, should have been part of the OnRowClick event object.
