Can you not just focus the next field? Assuming your fields are all at the
same level, just:

$(/* current component */).next('input,select,textarea,button')[0].focus();

Does that makes sense?

--Erik


On 9/14/07, Mark <[EMAIL PROTECTED]> wrote:
>
>
> Hi,
> I have a very large and complex form, and I am using some autocomplete
> components, and I need when user selects one item in the autocomplete
> option list, focus automatically go to the next component, like
> pressing the tab key.
>
> So, I am trying to simulate a tab key press on a component, with no
> success. I mean, sending a tab key to a component, just like if
> someone had pressed it.
>
> Using $item.keypress() or $item.keydown() there is no way to add the
> needed keyCode=9
>
> I had no luck using trigger('keydown',[{keyCode:9}]); either, I dont
> know if I am sending right the second parameter, but seems that no
> event is called at all.
>
> If anyone know how to this, please help, it is really needed to finish
> this project.
>
> Thanks in advance,
>
> Bye
> Mark
>
>

Reply via email to