WebSite1/connection.aspx.cs
(开头部分) 3KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Data.SqlClient;
public partial class WebSite1_connection : System.Web.UI.Page
{
string STconnection = ConfigurationSettings.AppSettings["strconnection"];
SqlConnection Strconn = null;
protected void Page_Load(object sender, EventArgs e)
{
msn.Text = Session["NiName"].ToString();
TextBox1.Text = msn.Text;
/* SqlConnection Strconn2 = null;
try
{
Strconn2 = new SqlConnection(STconnection);
Strconn2.Open();
SqlCommand cd = new SqlCommand("select* from JianLi_User where User_Name='" + Session ["NiName"].ToString() + "'", Strconn2);
SqlDataReader reader = cd.ExecuteReader();
Label3.Text = reader["Email"].ToString();
reader.Close();
}
catch (Exception e2) { Response.Write(e2); }
finally { Strconn2.Close(); };
* */
Smsg();
}
public void Smsg()
{
// Label3.Text.Trim();
string StrSql = "select* from JianLi_Message order by Mess_Datetime desc";
Strconn = new SqlConnection(STconnection);
try
{
Strconn.Open();
SqlDataAdapter dapter = new SqlDataAdapter(StrSql, Strconn);
DataSet ds = new DataSet();
dapter.Fill(ds, "JianLi_Message");
messagelist.DataSource = new DataView(ds.Tables [0]);
messagelist.DataBind();
}
catch (Exception e1) { Response.Write(e1); }
finally { Strconn.Close(); }
}
protected void LinkButton1_Click(object sender, EventArgs e)
{
Response.Redirect("../WebSite1/Help.aspx");
}
后面还有 35 行代码,解锁后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。