这个问题的解决方案有不少,但有些方法总会出问题,下面提一个终极解决办法做参考
思路:在父页面提交一个LinkButton按钮,让其隐藏,关闭子页面的时候让LinkButton onclick事件重新刷新页面。
首先在父页面添加一个LinkButton让其text为空,那么就可以隐藏LinkButton,然后注册这个按钮的js,LinkButton.Attributes.Add("onfocus", "javascript:__doPostBack('btnFresh','');");
添加一段JS代码
var sReturn=window.showModalDialog("" + id,'','dialogWidth:420px;dialogHeight:570px,center=yes,status=no,resizable=no,scroll=no,dialogHide=on');;
if (typeof(sReturn) != "undefined")
{
if (sReturn=="1")
{
document.all["btnFresh"].focus();
}
}
然后在子页面提价一下JS代码
function reload()
{
window.parent.returnValue='1';window.close();
}
因为是showModalDialog 所以记住加入 <base target="_self"/>
0
0
C语言中的static关键字
Linux下clock计时函数学习
open-falcon之dashboardportal说明.md
open-falcon之graph
open-falcon之query
open-falcon之HBS
open-falcon之judge
open-falcon之transfer
open-falcon之agent
- 最新文章
-
学习笔记:MySQL Big DELETEs 删除大量数据
mysql 5.5 数据库 utf8改utf8mb4
Quick and Easy Installation of Oracle Database 12c on Oracle Linux in Oracle VM VirtualBox
MySQl新特性 GTID
Linux中 /proc/[pid] 目录各文件简析
proxysql on github
176条DevOps人员常用的linux命令速查表
实战分析: MySQL字符集
MySQL: Connection Character Sets and Collations
运维安全之Tripwire
Copyright © 2011-2022 走看看