zoukankan      html  css  js  c++  java
  • asp.net 上一条和下一条记录的显示

    这里我用的是input标签跳转页面的:

    前台aspx页面中:

    <input class="btn" id="btnSetForm" type="button" value="设置考核关系" onclick="location.href ='../CompanyAdmin/AppraiseRelation.aspx?eid=<%=EmployeeID%>';"/>   //当前记录
         &nbsp;
         <input class="btn" id="Button3" type="button" value="为上个人设置考核表" onclick="location.href ='../CompanyAdmin/SetForm.aspx?eid=<%=EmployeeID_0%>';"/>  //当前的前一条记录
         &nbsp;
         <input class="btn" id="Button1" type="button" value="为下个人设置考核表" onclick="location.href ='../CompanyAdmin/SetForm.aspx?eid=<%=EmployeeID_1%>';"/>  //当前的后一条记录

    其中EmployeeID_0 ,EmployeeID, EmployeeID_1分别是上一条、当前、下一条记录的ID

    sql语句:@ID为当前EmployeeID

    上一条:select top 1 ID,RealName from OPA_Employee where EmployeeID<@EmployeeID order by ENumber desc //降序,取相邻第一个

    下一条:select top 1 ID,RealName from OPA_Employee where EmployeeID>@EmployeeID order by ENumber asc //升序,取相邻第一个(默认为升序)

    后台aspx.cs页面中调用:

    EmployeeID_0=user.getBefore(EmployeeID).ID;

    EmployeeID_1=user.getNext(EmployeeID).ID;


        

  • 相关阅读:
    【转】CNN卷积神经网络_ GoogLeNet 之 Inception(V1-V4)
    【转】Caffe的solver文件配置
    python 从filelist.txt中拷贝文件到另一文件夹中
    【转】fscanf 跳过空格,读取一行
    caffe配置NCCL
    caffe实现多任务学习
    mysql 2
    mysql 1
    mysql
    jQuery
  • 原文地址:https://www.cnblogs.com/dreamzcy/p/3170946.html
Copyright © 2011-2022 走看看