views:

310

answers:

2

Hi!

Some drop down lists on my project have so many options that I'm changing those to input texts with an autocomplete function (using jquery autocomplete plugin).

But, in drop down lists I can use a change event and use its value to fire an ajax function, for example. But, with an autocomplete, I don't know how to do that and I want to keep the change event. When I use the change event, nothing happens, or just works and there's some value on the input text and you erase its text and blurs.

Summaring: I want to use an change event on a autocomplete input text.

Thanks!!

A: 

If I understood your problem correctly, you could use the keyup event to fire a function everytime a key is pressed and released in the input field.

Davide Gualano
A: 

There are various options, including functions that are called at various stages of the autocomplete workflow, which you can specify. I would suggest sticking your logic in the FormatItem function.

Details are in the jQuery API.

Robert Grant