如何解决窗口弹出并刷新页面问题! 我点击A页面上一个按钮事件,弹出一个新页面窗口,然后在点击新页面窗口的提交按钮!我希望能提交成功,并且关闭新窗口页面,然后刷新下之前的A页面!窗口页面的后台代码Response.Write("<script>alert('Excle表导入成功!');</script>"); 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 <html xmlns="http://www.w3.org/1999/xhtml"><head runat="server"> <title>A也面</title> <script type="text/javascript" src="js/jquery-1.3.2.min.js"></script> <script type="text/javascript"> function WOpen(){ window.open("Default2.aspx"); } </script></head><body> <form runat="server"> <a onclick="WOpen()">打开</a> <%=DateTime.Now.ToString() %> </form></body></html><html xmlns="http://www.w3.org/1999/xhtml"><head runat="server"> <title>B页面</title></head><body> <form id="form1" runat="server"> <div> <input id="Text1" name="Text1" type="text" /> <input id="Submit1" type="submit" value="submit" /> </div> </form></body></html> if (Request.Form["Text1"] != null) { //插入 Response.Write("<script>window.close();window.opener.location.href=window.opener.location.href</script>"); } 第一页:protected void Button1_Click(object sender, EventArgs e) { Response.Write("<script>window.open('default2.aspx')</script>"); }第二页: Response.Write("<script>alert('提交成功');window.opener.location.href=window.opener.location.href;window.close()</script>"); 关于操作Excel多个Sheet的问题 oracle 中的 select 怎么用? 我的DataGrid表格的编辑、更新、取消的列太窄了,如何控制一下? 如何动态为表格添加新行 DataList的问题,在线等待..... 怪问题,请思归等高手帮忙 asp.net中的简单问题! 请教:关于dbf的连接及查询 我要跳楼了,大虾求救---脚本库的连接 怎样再.cs里,定义控件的高度???????? asp.net web应用程序打包 制做textbox+button的用户控件的代码
<head runat="server">
<title>A也面</title>
<script type="text/javascript" src="js/jquery-1.3.2.min.js"></script>
<script type="text/javascript">
function WOpen(){
window.open("Default2.aspx");
}
</script>
</head>
<body>
<form runat="server">
<a onclick="WOpen()">打开</a>
<%=DateTime.Now.ToString() %>
</form>
</body>
</html><html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title>B页面</title>
</head>
<body>
<form id="form1" runat="server">
<div>
<input id="Text1" name="Text1" type="text" />
<input id="Submit1" type="submit" value="submit" />
</div>
</form>
</body>
</html> if (Request.Form["Text1"] != null)
{
//插入
Response.Write("<script>window.close();window.opener.location.href=window.opener.location.href</script>");
}
{
Response.Write("<script>window.open('default2.aspx')</script>");
}
第二页:
Response.Write("<script>alert('提交成功');window.opener.location.href=window.opener.location.href;window.close()</script>");