<body onload=document.getElementById("ImageButton3").click()><input type=image id=ImageButton3 onclick=alert("没有错!")>---------------------------------------

解决方案 »

  1.   

    我在子頁面中找父頁面中的ImageButton3控件
    然后觸發它的click事件
    是不是這樣寫的?
      

  2.   

    没错是怎么写的 不过你要确定 打开 弹出窗口的父窗口中id为ImageButton3的控件存在,并且有onclick事件
      

  3.   

    有,這句話不執行,
    如果換成Button的話,它就執行
    真是搞不明白
      

  4.   

    index.htm
    -----------------------------------------
    <input type=button onclick=window.open("main.htm","","width=300,height=300") value=打开新窗口>
    <input type=image id=ImageButton3 onclick=alert("真的没有错!")>
    -----------------------------------------main.htm
    -----------------------------------------
    <body onload=window.opener.document.getElementById("ImageButton3").click()>
    -----------------------------------------