打开窗口的Javascript [英] Javascript for opening the window

查看:92
本文介绍了打开窗口的Javascript的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我正在使用Java脚本打开一个窗口.它可以在Chrome和mozila中正常工作,但不能在IE中工作.它将错误作为无效参数抛出.这是代码:

Hi,

I am using the java script to open a window. Its working fine in Chrome and mozila but it is not working in IE. It throws the error as invalid argument. Here is the code:

private void OpenWindow(String FileName, string WindowName)
   {
String script = @"<script language=''javascript''>" + "window.open(''" + FileName + "''," + "''width=550,height=400,toolbar=no,location=no,directories=no,status=no,menubar=no, scrollbars=no,resizable=yes,copyhistory=no'');" + "</script>";
ClientScript.RegisterStartupScript(this.GetType(), "OpenWindow", script);
    }


protected void AttachDocument_Click(object sender, EventArgs e)
    {
        String BidId = Convert.ToString(ViewState["BidId"]);
        OpenWindow("FileChooser.aspx?value=" + BidId, "");
    }

推荐答案

检查这些链接,我认为它会为您提供帮助:
Check these link i think it will help you :link [Register]


而不是使用yesno而是使用01
rather than using yes and no use 0 and 1


这篇关于打开窗口的Javascript的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆