ClientScript.GetCallbackEventReference()可实现服务器数据回传 局部刷新客户端 有什么其他方法可以不将数据发送到服务器后 返回数据局部刷新吗 就是做一个文本框的验证 用js验证 然后直接局部刷新数据 
    ,-~~-.___. 
   / |  '     \ 
  (  )        0 
   \_/-, ,----' 
      ====           // 
     /  \-'~;    /~~~(O)
    /  __/~|   /       |
  =(  _____| (_________|

解决方案 »

  1.   

    不需要服务器,那你就直接写javascript嘛
      

  2.   

    是这样的 我用ClientScript.GetCallbackEventReference()传参数到服务器 然后服务器传过来的值是一个参数 但是我想传回来2个参数 我就在服务器把2个参数和一起然后在客户端截取 第一个参数给ClientScript.GetCallbackEventReference()就刷新了局部值 但是第二次参数我获取后不知道把它怎么赋给令一个文本框 
      

  3.   


    客戶端 
    <script language="javascript">
    function click(ref)
    {
    <%=Page.ClientScript.GetCallbackEventReference(this,"ref","nullfunction",null) %>;
    }
    function nullfunction(n)
    {
      if(n!="")
      {
        //顯示ddd
        document.getElementById("txtRef").value=n;
        return false;
      }
      
    }
    </script>
    <input type="button" onclick="click("ddd")" value="獲取">
    <input type="text" > 服務器端
    先繼承 ICallbackEventHandler類
     #region ICallbackEventHandler 成員
         public string reMsg;
        public string GetCallbackResult()
        {
            return reMsg;
        }    public void RaiseCallbackEvent(string eventArgument)
        {
            if (!string.IsNullOrEmpty(eventArgument))
            {
                   reMsg = eventArgument;    
             } 
        }    #endregion
      

  4.   

    document.getElementById("txtRef").value=n;  要的就是这句感谢 怎么看怎么眼熟 ⊙﹏⊙b汗