October 2010
Intermediate to advanced
1920 pages
73h 55m
English
AutoCompleteExtender with a Web Service MethodIf you prefer, you can retrieve the auto-complete suggestions from a separate web service instead of a page method. For example, the web service in Listing 39.2, the FileService web service, retrieves a list of matching filenames from the file system.
Listing 39.2. FileService.asmx

The web service in Listing 39.2 includes a web method named GetSuggestions() that returns a list of filenames that match the prefix text passed to the web method. A LINQ query is used to return the matching results.
The FileService class is decorated with a ScriptService attribute. This attribute is required ...