UserSelect.aspx
上传用户:tiancihang
上传日期:2014-03-12
资源大小:21387k
文件大小:4k
源码类别:

.net编程

开发平台:

C#

  1. <%@ Page Language="C#" AutoEventWireup="true" CodeFile="UserSelect.aspx.cs" Inherits="UserSelect" %>
  2. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  3. <html xmlns="http://www.w3.org/1999/xhtml" >
  4. <head runat="server">
  5.     <title>选择回退主管帐户</title> 
  6.     <base target="_self" /> 
  7. </head>
  8. <body>
  9.     <form id="form1" runat="server">
  10.     <div>       
  11.         <table border="0" cellpadding="0" cellspacing="0" width="100%">
  12.     <tr><td>
  13.         请选择回退主管帐户</td></tr>
  14.     <tr><td>
  15.      <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" Width="100%"
  16.      BackColor="#CDCDCF" BorderWidth="0px"
  17.              CssClass="Grid"  SelectedRowStyle-CssClass="SelectedRow" HeaderStyle-CssClass="GridHeader" RowStyle-CssClass="HeadingCellText" 
  18.   FooterStyle-CssClass="GridFooter"  ShowFooter="true" CellSpacing="1" CellPadding="0"
  19.    HeaderStyle-ForeColor="black"   HeaderStyle-Font-Size="12px"  HeaderStyle-Font-Underline="false"   AllowPaging="True" AllowSorting="True"
  20.    OnPageIndexChanging="GridView1_PageIndexChanging"  OnRowCommand="GridView1_RowCommand" DataKeyNames="UserID">
  21.          <AlternatingRowStyle BackColor="#F0F0F0" />
  22. <RowStyle BackColor="#F9FAFC" CssClass="HeadingCellText" />
  23. <HeaderStyle Height="25px" BackColor="#DFDFDF" CssClass="GridHeader" />
  24.          <Columns>             
  25.              <asp:BoundField DataField="EmpName" HeaderText="职工姓名" />             
  26.             <%-- <asp:BoundField DataField="OrgName" HeaderText="组织机构" />--%>
  27.               <asp:TemplateField HeaderText="   操 作" >
  28.                <ItemTemplate>
  29.                 <asp:ImageButton ToolTip="选择" ID="IB_Select" runat="server" CommandName="Select" ImageUrl="~/Images/i_rate.gif"/>                                      
  30.                </ItemTemplate>
  31.                </asp:TemplateField>         
  32.          </Columns>
  33.          <FooterStyle CssClass="GridFooter" />
  34. <PagerStyle CssClass="GridPage" />
  35.             <PagerTemplate>
  36.                 <asp:Label  ID="LabelCurrentPage" runat="server">当前页:<%# ((GridView)Container.NamingContainer).PageIndex + 1 %></asp:Label>&nbsp; &nbsp;
  37.                 <asp:Label ID="LabelPageCount" runat="server" >总页数:<%# ((GridView)Container.NamingContainer).PageCount %></asp:Label>&nbsp; &nbsp;
  38.                 <asp:LinkButton ID="LinkButtonFirstPage" runat="server" CommandArgument="First" CommandName="Page" Enable="<%# ((GridView)Container.NamingContainer).PageIndex != 0 %>">首页</asp:LinkButton>&nbsp; &nbsp;
  39.                 <asp:LinkButton ID="LinkButtonPreviousPage" runat="server" CommandArgument="Prev" CommandName="Page" Enable="<%# ((GridView)Container.NamingContainer).PageIndex != 0 %>">上一页</asp:LinkButton>&nbsp; &nbsp;
  40.                 <asp:LinkButton ID="LinkButtonNextPage" runat="server" CommandArgument="Next" CommandName="Page" Enable="<%# ((GridView)Container.NamingContainer).PageIndex != ((GridView)Container.NamingContainer).PageCount - 1 %>">下一页</asp:LinkButton>&nbsp; &nbsp;
  41.                 <asp:LinkButton ID="LinkButtonLastPage" runat="server" CommandArgument="Last" CommandName="Page" Enable="<%# ((GridView)Container.NamingContainer).PageIndex != ((GridView)Container.NamingContainer).PageCount - 1 %>">尾页</asp:LinkButton>&nbsp; &nbsp;
  42.                 转到第:<asp:TextBox ID="LinkTextBoxNewPage" runat="server" Width="20px" Text='<%# ((GridView)Container.Parent.Parent).PageIndex + 1 %>'></asp:TextBox>页&nbsp; &nbsp;
  43.                 <asp:RangeValidator ID="RangeValidator1" runat="server" ErrorMessage="0-99999" ValidationGroup="goto" ControlToValidate="LinkTextBoxNewPage"
  44.                  MaximumValue="99999" MinimumValue="0" Display="Dynamic" ></asp:RangeValidator>
  45.                 <asp:linkbutton id="btnGo" runat="server" causesvalidation="False" commandargument="-1" commandname="Page" text="GO" ValidationGroup="goto" /> 
  46.             </PagerTemplate>                                
  47.             <HeaderStyle Font-Size="12px" Font-Underline="False" ForeColor="Black" />
  48.         </asp:GridView>
  49.     </td></tr>
  50.     </table>      
  51.     </div>
  52.     </form>
  53. </body>
  54. </html>