大佬教程收集整理的这篇文章主要介绍了从codebehind打开jQuery Dialog,大佬教程大佬觉得挺不错的,现在分享给大家,也给大家做个参考。
有人可以给我一个解决方法吗?这将是apreciated.
谢谢.
我的aspx:
HEAD <script type="text/javascript"> function BindEvents() { $.fx.speeds._default = 1000; $(document).ready(function () { var dlg = $("#DivMostrarIguales").dialog({ autoOpen: false,show: "fold",hide: "clip",width: 500,height: 500 }); dlg.parent().appendTo(jQuery("form:first")); }); } </script> ENDHEAD <asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server"> <asp:updatePanel runat="server" ID="up@R_849_10586@l"> <ContentTemplate> <script type="text/javascript"> Sys.Application.add_load(BindEvents); </script>.... <tr> <td class="Izquierda"> (*) Número único: </td> <td class="Derecha"> <asp:TextBox ID="tbNumeroUnico" runat="server"></asp:TextBox> <asp:Button ID="btMostrarIgualesEntrante" runat="server" Text="Revisar si ya existe" OnClick="MostrarVentanaIgualesEntrante" ValidationGroup="none" CausesValidation="false" CssClass="Button" /> <asp:Label runat="server" ID="lbNumeroUnicoEntrante" Text="Debe digitar el formato correcto del número único (completo)" Visible="false" CssClass="ErrorCampo"></asp:Label> </td> </tr>... <div id="DivMostrarIguales" title="Número Único Igual"> whatEver </div> </ContentTemplate> </asp:updatePanel> </asp:Content>
我的.CS功能:
private String getjQueryCode(String jsCodetoRun) { StringBuilder sb = new StringBuilder(); sb.AppendLine("$(document).ready(function() {"); sb.AppendLine(jsCodetoRun); sb.AppendLine(" });"); return sb.ToString(); } private void runjQueryCode(String jsCodetoRun) { ScriptManager requestSM = ScriptManager.GetCurrent(this); if (requestSM != null && requestSm.IsInAsyncPostBACk) { ScriptManager.RegisterClientScriptBlock(this,typeof(PagE),Guid.NewGuid().ToString(),getjQueryCode(jsCodetoRun),truE); } else { ClientScript.RegisterClientScriptBlock(typeof(PagE),truE); } } protected void MostrarVentanaIgualesEntrante(object sender,EventArgs E) { CargarGridMostrarIgualesEntrante(); runjQueryCode("$('#DivMostrarIguales').dialog('open')"); }
以上是大佬教程为你收集整理的从codebehind打开jQuery Dialog全部内容,希望文章能够帮你解决从codebehind打开jQuery Dialog所遇到的程序开发问题。
如果觉得大佬教程网站内容还不错,欢迎将大佬教程推荐给程序员好友。
本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。