# Behavior when pressing the TAB key on keyboard

**URL:** <https://techcommunity.softwareag.com/t/behavior-when-pressing-the-tab-key-on-keyboard/57306>\
**Category:** Forum\
**Tags:** Former-Crossvision-Products, Application-Composer\
**Created:** [April 20, 2006, 11:56pm UTC](https://techcommunity.softwareag.com/t/behavior-when-pressing-the-tab-key-on-keyboard/57306 "2006-04-20T23:56:01Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Konstantin](https://avatars.discourse-cdn.com/v4/letter/k/858c86/32.png) [@Konstantin](https://techcommunity.softwareag.com/u/Konstantin)\
**Post date:** [April 20, 2006, 11:56pm UTC](https://techcommunity.softwareag.com/t/behavior-when-pressing-the-tab-key-on-keyboard/57306/1 "2006-04-20T23:56:01Z")

</div>

Hi there,

I am trying to do the following thing.

Let’s say you have 4 Input Fields A, B and C, D.  
Tabindex for A = 1  
Tabindex for B = 2  
Tabindex for C = 3  
Tabindex for D = 4

Now you want B, C and D to be disabled in the beginning.  
So I used the Binding - statusprop Attribute (lets say testStatus) and defined my own method inside my Adapter Code. The method is called getTestStatus and if lenfth of input of A \> 0 it should become editable that moment or at least when exiting the input field by pressing TAB on keyboard. The moment a field control is disabled though, it jumps directly to the next editable control. So neither I manage to jump to my next Tabindexed Field which should be B, nor I manage to make it editable.

How can I use a keoboard listener in CAI ?

How can I make a field editable on demand?

Does anyone has experience with Keyboard handling?  
Thanks in advance!

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/techcommunity/original/3X/c/d/cd19967bb605d28a72d77eb83a1cae22f3df2eb8.svg) [@system](https://techcommunity.softwareag.com/u/system)\
**Post date:** [April 21, 2006, 10:44am UTC](https://techcommunity.softwareag.com/t/behavior-when-pressing-the-tab-key-on-keyboard/57306/2 "2006-04-21T10:44:09Z")

</div>

Hi Konstantin,  
please use attribute FLUSH with FIELD/… in order to directly react on user leaving a changed field. Please have a look into the corresponding docu.  
Bjoern

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/techcommunity/original/3X/c/d/cd19967bb605d28a72d77eb83a1cae22f3df2eb8.svg) [@system](https://techcommunity.softwareag.com/u/system)\
**Post date:** [April 2, 2021, 2:38pm UTC](https://techcommunity.softwareag.com/t/behavior-when-pressing-the-tab-key-on-keyboard/57306/3 "2021-04-02T14:38:32Z")

</div>


