title: Asp.net ajax pagemethods not working
body: <p>I have a project that originally did not use ajax. Now I want to make the page ajax enabled. What I did already is Install the ajaxToolkit and replace the web.config content with another one from an ajax enabled web site. I added Script Manager:</p>
  
  <pre><code>&lt;form id="Form1"  runat="server"&gt;
  &lt;asp:ScriptManager ID="ScriptManager1" runat="server" EnablePageMethods="True" EnableScriptGlobalization="True" /&gt;
  </code></pre>
  
  <p>my method in the .cs file looks like this</p>
  
  <pre><code>[WebMethod]
  public static string[] CheckRating(string[] details)
  {
      string[] result = new string[] { "AAAAAAAAAAA", "" };
      return result;
  }
  </code></pre>
  
  <p>my java script functions are:</p>
  
  <pre><code> function someName() {
  
          var details = new Array();
          details[0] = $("#HiddenFieldUsername").val();
          details[1] = "5310005003117";
          PageMethods.CheckRating(details, ss1, ss2);
      }
      function ss1(result, userContext, methodName)
      {
          $("#user_rating").show();
          $("#user_rating_text").html("Error User ratinh");
          alert("Sorry");
      }
      function ss2(error, userContext, methodName) {
          $("#user_rating").show();
          $("#user_rating_text").html("Error User ratinh");
          alert("Sorry");
      }
  </code></pre>
  
  <p>The problem is when it gets here: PageMethods.CheckRating(details, ss1, ss2);
  nothing happens. None of the code in ss1 or ss2 is executed... java scripts just stop working.</p>