views:

919

answers:

2

Hi -

I have an application currently using the AJAX Toolkit AutoCompleteExtender to extend a textbox. It is using a webservice to select and retrieve the data. The docs for the toolkit say that you can also use a page service and I have been trying for days to get that to wrok - both in the vs2005 and the 2.0 framework version and vs2008 and the 3.5 framework version (the attrubutes for the page service are slightly different in each version). I cannot get either version to work with a page service - both work just fine with a web service.

Has anyone had any luck with this?

Thanks

+2  A: 

Have You checked the following:

  • Your page method is (You really mean page method, not page service?) is static.
  • The method return a List or string[].
  • The parameters are (string prefixText, int count). Order and case matters.

You can also look at http://allwrong.wordpress.com/2007/03/13/ms-ajax-autocomplete-extender-using-a-page-method/ .

/Andreas

A: 

Have you had a look at your page with either Firebug in FireFox or Fiddler with IE to actually see what (if anything) is going on with the scripts and network calls? Firebug's script tab will show you nicely what script methods have been loaded, and will show you network traffic between the browser and server on the Net tab, while Fiddler will mostly allow you to analyse and edit network traffic.

Are you using master pages, and is the control on the master page or the page itself - you can't have page methods on a masterpage?

Zhaph - Ben Duguid
Using MasterPages - everything is on the content page except the ScriptManager which I place on the MasterPage so that all content pages have it. Page method is in code behind of content page.
Jim Evans
Hmm, that all sounds about right - have you tried fiddler or firebug then? That would be my next step - see what is actually happening with the JS and over the network.
Zhaph - Ben Duguid
Will try that tonight (at the day job now) - thanks...
Jim Evans
Good luck, let us know how you get on.
Zhaph - Ben Duguid