Generic handler (ashx) not rising with jquery autocomplete plugin

2.6k views Asked by At

My generic handler is not being called when using autocomplete,

I have this in my .aspx page.

 $(document).ready(function () {
     $("#test").autocomplete("Handlers/MyHandler.ashx");
 }

with this files included jquery-1.4.2.min.js and jquery-ui-1.8.custom.min.js

I put a breakpoint on server never is reached, also used firebug to see if jquery is making its request and nothing, could be a bug with the plugin?

1

There are 1 answers

2
The Scrum Meister On BEST ANSWER

You are not initializing the jQuery ui autocomplete properly, pass a object with a source property:

$(document).ready(function () {
     $("#test").autocomplete({source: "Handlers/MyHandler.ashx"});
 }

Passing a string directly is used to access one of its methods, for example:

$("#test").autocomplete("enable");