title: WebMethod not being called. ASP.NET C#
body: <p>I followed a very simple example of autocompletion using ajax and cannot get mine to work. I stepped threw the code and it looks like it never goes to my webmethod. What else is there to check? </p>
  
  <p><strong>.aspx</strong></p>
  
  <pre><code>    &lt;asp:ScriptManager ID="ScriptManager1" runat="server"&gt;
  
      &lt;/asp:ScriptManager&gt;
  
  &lt;asp:TextBox ID="txtFrom" runat="server"&gt;
  &lt;/asp:TextBox&gt;
  &lt;ajaxToolkit:AutoCompleteExtender ID="AutoCompleteExtender1" runat="server" TargetControlID="txtFrom" MinimumPrefixLength="1" ServiceMethod="GetSuggestions"&gt;
  &lt;/ajaxToolkit:AutoCompleteExtender&gt;
  </code></pre>
  
  <p><strong>.aspx.cs</strong></p>
  
  <pre><code>[System.Web.Services.WebMethod]
  [System.Web.Script.Services.ScriptMethod]
  public static string[] GetSuggestions(string prefixText, int count, string contextKey)
  {
      string[] members = { "Nick", "John", "Bob" };
  
      return (from m in members where m.StartsWith(prefixText, StringComparison.CurrentCultureIgnoreCase) select m).Take(count).ToArray();
  }
  </code></pre>
  
  <p>I created a webservice to use instead of putting my method directly in the class, but I get the same result. </p>