 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
somchai Guest
|
Posted: Sun May 28, 2006 7:27 am Post subject: How to Used Enter To change next Component? |
|
|
Hi,
I am using a TIWEdit1, TIWEdit2, TIWEdit3,........ and it using Tab to
change next component.
I would like to use Enter to change next component.
Has anyone used this component and been able to trap this event?
How can it be done?
Thanks
ps. This javaScript to trap Enter
function nextCtr(input)
{
if(window.event.keyCode == 13)
{
var index = getIndex(input);
if(index < input.form.length-1)
input.form[index+1].focus();
else
input.form[0].focus();
}
//alert(getIndex(input));
}
function getIndex(input) {
var index = -1, i = 0;
while (i < input.form.length && index == -1)
if (input.form[i] == input)index = i;
else i++;
return index;
} |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|