📄 elect.aspx
字号:
<%@ Page Language="C#" MasterPageFile="~/MasterPage2.master" AutoEventWireup="true" CodeFile="elect.aspx.cs" Inherits="_Default" Title="Untitled Page" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
<table >
<tr>
<td align="center" style="width: 100px; text-align: center; height: 10px;" valign="top">
</td>
</tr>
<tr>
<td align="center" style="width: 100px; text-align: center" valign="top">
<table style="text-align: center; background-color: #ff9999; width: 853px;">
<tr>
<td style="height: 100px;" colspan="8">
<asp:GridView ID="GridView1" runat="server" AllowPaging="True" AutoGenerateColumns="False" Width="847px" OnPageIndexChanging="Data_Page" PageSize="5" OnRowDeleting="GridView1_RowDeleting" DataKeyNames="courceID,teaID" CellPadding="4" ForeColor="#333333" GridLines="None">
<Columns>
<asp:BoundField DataField="courceID" HeaderText="courceID" ReadOnly="True" Visible="False" SortExpression="courceID" />
<asp:BoundField DataField="teaID" Visible="False" HeaderText="teaID" ReadOnly="True" SortExpression="teaID" />
<asp:BoundField DataField="courceName" HeaderText="课程名称" SortExpression="courceName" />
<asp:BoundField DataField="typename" HeaderText="课程类别" SortExpression="typename" />
<asp:BoundField DataField="teaName" HeaderText="教师姓名" SortExpression="teaName" />
<asp:BoundField DataField="courceTime" HeaderText="上课时间" SortExpression="courceTime" />
<asp:BoundField DataField="courceAddress" HeaderText="上课地点" SortExpression="courceAddress" />
<asp:BoundField DataField="credit" HeaderText="课程学分" SortExpression="credit" />
<asp:BoundField DataField="xueshi" HeaderText="课程学时" SortExpression="xueshi" />
<asp:BoundField DataField="courcerenshu" HeaderText="限选人数" SortExpression="courcereshu" />
<asp:BoundField DataField="renshu" HeaderText="已选人数" SortExpression="renshu" />
<asp:HyperLinkField DataNavigateUrlFields="courceID,teaID" DataNavigateUrlFormatString="courseDetail.aspx?courceID={0}&teaID={1}"
HeaderText="详细..." Text="详细..."/>
<asp:ButtonField CommandName="delete" HeaderText="退选" Text="退选">
<ItemStyle Width="60px" Wrap="False" />
<HeaderStyle Wrap="False" />
</asp:ButtonField>
</Columns>
<FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
<RowStyle BackColor="#EFF3FB" />
<EditRowStyle BackColor="#2461BF" />
<SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
<PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" />
<HeaderStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
<AlternatingRowStyle BackColor="White" />
<PagerTemplate>
<table>
<tr>
<td>
<asp:Label ID="LabelCurrentPage" runat="server" Font-Size="Small">当前页:<%# ((GridView)Container.NamingContainer).PageIndex + 1 %></asp:Label></td>
<td>
<asp:Label ID="LabelPageCount" runat="server" Font-Size="Small">总页数:<%# ((GridView)Container.NamingContainer).PageCount %></asp:Label></td>
<td>
<asp:LinkButton ID="LinkButtonFirstPage" runat="server" CommandArgument="First" CommandName="Page"
Enable="<%# ((GridView)Container.NamingContainer).PageIndex != 0 %>" Font-Size="Small">首页</asp:LinkButton></td>
<td>
<asp:LinkButton ID="LinkButtonPreviousPage" runat="server" CommandArgument="Prev"
CommandName="Page" Enable="<%# ((GridView)Container.NamingContainer).PageIndex != 0 %>"
Font-Size="Small">上一页</asp:LinkButton></td>
<td>
<asp:LinkButton ID="LinkButtonNextPage" runat="server" CommandArgument="Next" CommandName="Page"
Enable="<%# ((GridView)Container.NamingContainer).PageIndex != ((GridView)Container.NamingContainer).PageCount - 1 %>"
Font-Size="Small">下一页</asp:LinkButton></td>
<td>
<asp:LinkButton ID="LinkButtonLastPage" runat="server" CommandArgument="Last" CommandName="Page"
Enable="<%# ((GridView)Container.NamingContainer).PageIndex != ((GridView)Container.NamingContainer).PageCount - 1 %>"
Font-Size="Small">尾页</asp:LinkButton></td>
</tr>
</table>
</PagerTemplate>
</asp:GridView>
</td>
</tr>
<tr>
<td style="height: 34px; text-align: center;" colspan="8">
</td>
</tr>
</table>
</td>
</tr>
</table>
</asp:Content>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -