[英]creating a pop-up in asp.net?
我想用選項按鈕和文本框創建一個彈出窗口。
檢查我的代碼..
<form id="frmInsuranceCarrier" runat="server">
<div>Enter a New Insurance Carrier Code</div>
<div>
<asp:RadioButton ID="optAutoAssign" runat="server" />
Auto Assign</div>
<div>
<asp:RadioButton ID="optManual" runat="server" />
Manual</div>
<div>
<asp:TextBox ID="txtManual" runat="server"></asp:TextBox>
</div>
<asp:Button ID="cmdOk" runat="server" Text="Ok" onclick="cmdOk_Click" />
<asp:Button ID="cmdCancel" runat="server" Text="Cancel"
onclick=
“ cmdCancel_Click” />
在處理彈出窗口時,這里沒有太多代碼:)是否要使用ajax模態彈出窗口? 在這種情況下,請查看: http : //www.asp.net/ajax/ajaxcontroltoolkit/samples/modalpopup/modalpopup.aspx
jQuery模型是一個不錯的選擇。
執行每個javascript / jQuery代碼服務器端
public void AnyButton_Click(Object sender, EventArgs e)
{
string script = "$('#theid').dialog('open');";
ClientScript.RegisterStartupScript(GetType(), "popup", script, true);
}
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.