弹出窗口进行一系列运行,得到一个变量filenames把filename直接返回父窗口的TextBox1这样行的opener.form1.fujian.value  = 'filenames'; ,把filename定义为变量返回父窗口的Text这样就不行
opener.form1.fujian.value  = '"+filename+"'; 变量该如何返回?

解决方案 »

  1.   

    opener.form1.fujian.value  = filename;
      

  2.   

    opener.form1.fujian.value  = "'"+filename+"'";
      

  3.   

    我其实是a页面中有一个文本框fujian,一个按钮,点击这个按钮,产生一个上传的对话框窗口b,当在b中选择好文件,点上传按钮,在C中处理上传了文件,我就是想在C中把上传的文件的文件名返回到A中的文本框fujian中
      

  4.   

    用showModalDialog弹出窗口
    var a=window.showModalDialog("sxbm_d.aspx?val="+str+"&id='"+str2+"'","newform","dialogHeight:400px; dialogWidth: 180px; center: Yes; help: Yes; resizable: Yes; status: NO;");
    if (a!="undefined" && a!="")
    {
    document.Form1.Hidden17.value=a;//返回的值
    document.Form1.Text1.value ="已设置权限";
    }