日期:2014-05-18  浏览次数:20406 次

请教大侠们一个困扰多时的问题
A页面 弹出框代码
function open(str)
  {
  //如需阻止窗口关闭,请在判断 action 值内加入 return false
  asyncbox.open({
   url :str,
   width : 350,
   height : 160,
   title:'信息弹出框',
   modal:true, 
   scroll:'no',
   wait:true, 
   //btnsbar : $.btn.OKCANCEL, //按钮栏配置请参考 “辅助函数” 中的 $.btn。
   callback : function(action){
     //嵌套使用 AsyncBox 中的 this 会改变,先存当前窗口的对象。
     var t = this;
     //判断 action 值。
     if(action == 'close'){
       asyncbox.confirm('关闭弹出窗口!','确认框',function(){
         //做了某些事情,然后关闭窗口。     
         $.close(t.id); 
         window.location.href=window.location.href;//主页面刷新
       });
       return false;
     }
    } 
  });
  }  
B页面
  <div style=" height:200px; width:350px; margin:0 auto;">
  <table class="table">
  <tr class="chead">
  <td>客户ID:</td>
  <td><asp:TextBox ID="TextBox1" runat="server"></asp:TextBox></td>
  </tr>
  <tr class="chead">
  <td>30C编号:</td>
  <td><asp:TextBox ID="TextBox2" runat="server"></asp:TextBox></td>
  </tr>
  <tr class="chead">
  <td>30C型号:</td>
  <td><asp:TextBox ID="TextBox3" runat="server"></asp:TextBox></td>
  </tr>
  <tr>
  <td><asp:Button ID="Button1" runat="server" Text="保存" OnClick="Button1_Click" OnClientClick="javascript:aaa()" /></td>
  <td><asp:Button ID="Button2" runat="server" Text="重置" /></td>
  </tr>
  </table>
  </div>
实现更新数据以后,弹出框关闭,数据更新。请问怎么做

------解决方案--------------------
window.location.href=window.location.href;//主页面刷新
这一句 数据就会更新
------解决方案--------------------
你现在不是写出来了吗?有什么问题?