zoukankan      html  css  js  c++  java
  • javascript子窗口传值给父窗口

     if (this.ListInfoClass.SelectedIndex >= 0)
            {
                
    if (Request.QueryString["TextID"!= null)
                {
                    
    string strScript = "<script>" + "\r\n";
                    strScript 
    += "window.opener.document.form1['" + Request.QueryString["TextID"].ToString() + "'].value='" + this.ListInfoClass .SelectedItem.Text  + "'" + "\r\n";
                    strScript 
    += "window.parent.close();" + "\r\n";
                    strScript 
    += "</script>" + "\r\n";
                    
    if ((!(IsClientScriptBlockRegistered("clientScript"))))
                    {
                        RegisterClientScriptBlock(
    "clientScript", strScript);
                    } 
                }
            }
            
    else
            {
                Response.Write(
    "<script language='javascript'>alert('请选择一个类别');</script>");
            }
  • 相关阅读:
    Vue无缝滚动
    vue+Axios 实现路由拦截和登录拦截
    添加删除数组元素的方法
    日期时间相关
    Vue源码编译过程
    new关键字执行过程
    预解析
    echarts图表数据为空的时候不显示气泡
    arguments使用
    log4net介绍很全面
  • 原文地址:https://www.cnblogs.com/ringwang/p/1445849.html
Copyright © 2011-2022 走看看