有关GridView中ImageButton控件后台代码弹出对话框如何写
这是我前台的 <asp:GridView> 的相关信息,其中<asp:ImageButton ID="ImageButton2" CommandName="UserUpdate" runat="server" ImageUrl="~/images/edit.PNG" CommandArgument='<%# Eval("userid") %>' /> 这句是用来转向修改界面的。
<asp:GridView ID="gvUserManage" runat="server" AllowPaging="True" Width="100%" CellPadding="1"
BorderWidth="1px" AutoGenerateColumns="False" RowStyle-HorizontalAlign="Center"
CssClass="GridViewStyle" PageSize="10" OnRowDataBound="gvUserManage_RowDataBound"
OnRowDeleting="gvUserManage_RowDeleting"
onrowcommand="gvUserManage_RowCommand">
<PagerStyle CssClass="GridViewPagerStyle" />
<HeaderStyle CssClass="GridViewHeaderStyle" />
<RowStyle CssClass="GridViewRowStyle" Height="25px" />
<AlternatingRowStyle CssClass="GridViewAlternatingRowStyle" />
<PagerSettings FirstPageText="首页" LastPageText="最后 1 页" NextPageText="下 1 页" PreviousPageText="上 1 页"
Mode="NumericFirstLast" />
<EmptyDataTemplate>
<font size="4pt">无数据!</font></EmptyDataTemplate>
<Columns>
<asp:TemplateField HeaderText="序号">
<HeaderStyle HorizontalAlign="Center" Width="40px"></HeaderStyle>
<ItemTemplate>
<%# gvUserManage.PageIndex * gvUserManage.PageSize + gvUserManage.Rows.Count + 1%>
</ItemTemplate>
</asp:TemplateField>
<asp:BoundField DataField="USERNAME" HeaderText="用户名" SortExpression="Sex" ItemStyle-HorizontalAlign="Center">
<ItemStyle HorizontalAlign="Center"></ItemStyle>
</asp:BoundField>
<asp:BoundField DataField="USERJC" HeaderText="登录名" SortExpression="Sex" ItemStyle-HorizontalAlign="Center">
<ItemStyle HorizontalAlign="Center"></ItemStyle>
</asp:BoundField>
<asp:BoundField DataField="rolename" HeaderText="角色" SortExpression="Sex" ItemStyle-HorizontalAlign="Center">
<ItemStyle HorizontalAlign="Center"></ItemStyle>
</asp:BoundField>
<asp:TemplateField HeaderText="操作" ItemStyle-HorizontalAlign="Center">
<ItemTemplate>