>>Hi everybody,
>>
>>I'm trying in DataEntry application don't use mouse and only use keyboard. I have a form to select DE file. It has a listbox to select. How can I make it to react on keys?
>
>Maybe I'm missing something but it's bultin into listbox. You can use arrow keys, page up/down, home/end to navigate and Enter/Space to trigger Click() event.
Nope. I have 4 objects on the form. First is combobox. I made a selection, then press Tab to move to the list (next control). It doesn't have anything activated yet (listindex=0). So, I could not do anything with keys to select item.
Anyway, I've solved this problem with the following code in ListBox.when:
if this.listindex = 0 and this.listcount>0
this.listindex = 1
thisform.cmdSelect.enabled = .t.
endif
If it's not broken, fix it until it is.
My Blog