reliangQuery.aspx.cs
(开头部分) 3KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;
public partial class reliangQuery : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack && Session["lname"] != null)
{
this.riqi.Text=DateTime.Now.ToString("yyyy-MM-dd");
BindData();
}
}
/// <summary>
/// 绑定
/// </summary>
private void BindData()
{
DataPage dp = new DataPage();
string where = " lname='" + Session["lname"].ToString() + "' ";
int recordcount;
int pagesize = this.AspNetPager1.PageSize;
int pageindex = this.AspNetPager1.CurrentPageIndex;
this.Repeater1.DataSource = dp.pagelist(pagesize, pageindex, "reliangview", " * ", "riqi", where, "riqi desc", out recordcount);
this.Repeater1.DataBind();
this.AspNetPager1.RecordCount = recordcount;
}
protected void Button1_Click(object sender, EventArgs e)
{
if (this.reliang.Text == "")
{
MessageBox.Show(this, "热量值不能为空!");
return;
}
try
{
int m = int.Parse(this.reliang.Text);
}
catch (Exception ex)
{
MessageBox.Show(this, "热量值必须为数字!");
return;
}
string lname = Session["lname"].ToString();
string riqi = this.riqi.Text;
string reliang= this.reliang.Text;
string sql = "select * from reliang where lname='" + lname + "' and riqi='" + riqi + "'";
string strsql = "";
DataSet ds = DbHelperSQL.Query(sql);
if (ds.Tables[0].Rows.Count > 0)
{
if (leixing.Text == "早")
{
strsql = "Update reliang set zao=" + reliang + " where lname='" + lname + "' and riqi='" + riqi + "'";
后面还有 39 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。