[英]C# Button click open many 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>
我如何只用一個按鈕就可以打開更多窗口?
<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>
預先謝謝你。
據我了解,您需要在窗口上使用不同的名稱。 所以測試一下:
window.open("http://www.google.se", "google");
window.open("http://msdn.microsoft.com/sv-se/", "msdn");
或您的情況:
window.open('PrintLettreVoit.aspx?Id=3','ID3');
window.open('PrintLettreVoit.aspx?Id=7','ID7');
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.