ASP.NET - how to add autocompleteextender in

Asked By sanket patil on 16-Feb-13 06:42 AM
Hi friends i have used autocompletextender in my C# form . but it's not working fine. i have used following code.

  <%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>

   <asp:ScriptManager ID="script" runat="server" EnablePageMethods="true">

   <asp:TextBox ID="txtServiceCityLocal" runat="server" Style="width: 292px; margin-left: 150px;
                                                    border: solid 1px #747474">

   <asp:AutoCompleteExtender ID="AutoCompleteExtender2" runat="server"
               TargetControlID="txtServiceCityLocal" ServiceMethod="GetCountries"
                ServicePath="~/WebService.asmx" MinimumPrefixLength="2"
                CompletionInterval="100" EnableCaching="false" CompletionSetCount="10">

    public List<string> GetCountries(string prefixText,int count)
        List<string> CountryNames = new List<string>();
        return CountryNames;

After implementation of this code i put debugger on GetCountries method. it's not calling this methode.

Danasegarane Arunachalam replied to sanket patil on 16-Feb-13 09:29 PM
Does the  method  "GetCountries" is on the same page or different page?