我有一个gridview
其中包含一个details button
作为最后一栏。
My aspx:
<asp:GridView Width="100%" ID="gv_NotApplied" CssClass="datatable" AllowSorting="True"
runat="server" TabIndex="2" AutoGenerateColumns="False" AllowPaging="True" GridLines="None">
<Columns>
<asp:TemplateField HeaderText="serial">
<ItemTemplate>
<asp:Label ID="lblSerial" runat="server"></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:BoundField HeaderText="name" DataField="crs_name" />
<asp:BoundField HeaderText="lecturer" DataField="name" />
<asp:TemplateField HeaderText="details">
<ItemTemplate>
<asp:ImageButton ID="Ibtn_Details" runat="server" ImageUrl="~/Images/detail.png"
CommandArgument='<%#((GridViewRow)Container).RowIndex%>' CommandName="Detail"
CausesValidation="false" />
</ItemTemplate>
</asp:TemplateField>
</Columns>
<RowStyle VerticalAlign="Top" CssClass="row" />
</asp:GridView>
我想做的是:
当用户点击details button
, open 弹出窗口(对话框窗口).
在此窗口中,我想放入一些 ASP.NET 服务器控件(如网格视图)。所以我希望这个窗口能够启用/允许我访问后面代码中的这些控件。
我建议您打开一个模态弹出窗口,例如colorbox http://colorpowered.com/colorbox/core/example1/index.html这个颜色框可以指向显示一个包含所有您想要的控件的aspx页面。颜色框将告诉您如何使按钮打开模式窗口以及如何将页面放入其中。
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)