简体   繁体   English

C#按钮单击打开许多窗口

[英]C# Button click open many windows

how can i do in ASP.NET(C#) only one button clic, i can open more than 1 windows ? 我怎样才能在ASP.NET(C#)中只有一个按钮,我可以打开多个窗口?

 <dx:ASPxButton ID="ASPxButton_PrintLetrVoit" runat="server" Text="Impression lettre de voiture" AutoPostBack="False">
                          <ClientSideEvents
                            Click="function (s, e) { e.processOnServer = false; window.open('PrintLettreVoit.aspx?Id=2'); }" />

                        </dx:ASPxButton>

how can i open more window only with one button clic ? 我如何只用一个按钮就可以打开更多窗口?

<dx:ASPxButton ID="ASPxButton_PrintLetrVoit" runat="server" Text="Impression lettre de voiture" AutoPostBack="False">
                          <ClientSideEvents
                            Click="function (s, e) { e.processOnServer = false;
                            var i=0;
                            for (i=0;i<=5;i++)                               
                             window.open('PrintLettreVoit.aspx?Id=i');                            
                             }" />
                        </dx:ASPxButton>

Thanks you in advance. 预先谢谢你。

What I understand you need to have different names on the windows. 据我了解,您需要在窗口上使用不同的名称。 So test this: 所以测试一下:

window.open("http://www.google.se", "google");
window.open("http://msdn.microsoft.com/sv-se/", "msdn");

Or in your case: 或您的情况:

window.open('PrintLettreVoit.aspx?Id=3','ID3');
window.open('PrintLettreVoit.aspx?Id=7','ID7');

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM