Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: HTML Ajax WebService
I have created a web service in .net which will retrieve the city name based on the given input text. The web service is working properly. I have used that web service in an AutoCompleteExtender Control in ajax control toolkit. But i am not getting the list of suggestions if i type anything in the textbox.
 
The web service structure is:
public string GetCompletionList(string prefixText)
 
The HTML file is:
<body>
    <form id="form1" runat="server">
<div>
.........................................
.........................................
.........................................
<asp:TextBox ID="txtsearchcity" runat="server" class="autosuggest"></asp:TextBox>
<asp:AutoCompleteExtender runat="server" 
        ID="autoComplete1" 
        TargetControlID="txtsearchcity" 
        ServicePath="http://localhost:3935/SearchCity/searchcity.asmx" 
        ServiceMethod="GetCompletionList"
        MinimumPrefixLength="2"
        CompletionInterval="1000" 
        EnableCaching="true" 
        CompletionSetCount="20">
</asp:AutoCompleteExtender>
.........................................
.........................................
.........................................
</div>
</form>
</body>
 
What should be the exact ServicePath and ServiceMethod???
Whether the css file is necessary to get the output???
 
Anybody Please help out...
Thanks in advance
Posted 20-Sep-12 2:48am

1 solution

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 Sergey Alexandrovich Kryukov 630
1 OriginalGriff 431
2 Maciej Los 210
3 PIEBALDconsult 180
4 Mehdi Gholam 145
0 Sergey Alexandrovich Kryukov 11,384
1 OriginalGriff 5,783
2 Maciej Los 5,684
3 CPallini 3,879
4 BillWoodruff 3,584


Advertise | Privacy | Mobile
Web02 | 2.8.141030.1 | Last Updated 20 Sep 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100