0

I want to change page width and height using RegisterStartupScpript method:

I tried

ScriptManager.RegisterStartupScript(this, this.GetType(), "default2", "<script height:350; width:200 type=text/javascript> </script>", true);

but it doesn't work. Can you help me? How can I do?

I find solution thanks for everone

      ScriptManager.RegisterStartupScript(this, typeof(string), "OPEN_WINDOW", "window.open( 'Default2.aspx?adi=" + adi + "&soyadi=" + soyadi + "&ogrenci_no="+ogrenci_no+"&tel_no="+tel_no+"&sinifi="+sinifi+"', 'height=650,width=850,status=no,toolbar=no,menubar=no,location=no, scrollbars=yes' );", true);
4

1 回答 1

0

使用 window.open 打开新窗口并设置新打开窗口的大小,您可能需要取消阻止弹出窗口。

现场演示按渲染按钮弹出

window.open ("http://www.javascript-coder.com","mywindow","menubar=1,resizable=1,width=350,height=250");
于 2012-06-28T09:16:33.137 回答