title: alert in WebMethod
body: <pre><code> [WebMethod]
   public string LoadLayout()
   {
          try
          {
              List&lt;XmlTag&gt; lstXmlTags = new List&lt;XmlTag&gt;();
              lstXmlTags = parser.GetXmlTags(filePath);
  
              string script = "&lt;script type=\"text/javascript\"&gt;alert(lstXmlTags );&lt;/script&gt;";
              System.Web.UI.ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "test", script, true);
  
          }
          catch (Exception ex)
          {
              throw ex;
          }
      }
  </code></pre>
  
  <p>I want to alert <code>lstXmlTags</code> for test purpose.Above code run locally but in server its get a problem.I think in server its doesn't able to get <code>filepath</code>.So I want to  alert what <code>lstXmlTags</code> returns or is it empty.So I  add <code>RegisterClientScriptBlock</code> for  showing result.But what I try gives me syntax error.I am not able to use <code>RegisterClientScriptBlock</code>.Thanks.</p>