您目前尚未登陆,请选择【登陆】或【注册
首页->行政办公->智能选课系统源码及论坛>>Admin/AdminLogin.aspx.cs>>代码在线查看
温馨提示:代码在线浏览功能只能做为源码浏览参考,不能展示项目的全部,如果想更进一步了解该代码请下载:智能选课系统源码及论坛


当前文件路径:XuanKeLunWen/Admin/AdminLogin.aspx.cs 文件类型
普通视图
		            
1using System; 2using System.Data; 3using System.Configuration; 4using System.Collections; 5using System.Web; 6using System.Web.Security; 7using System.Web.UI; 8using System.Web.UI.WebControls; 9using System.Web.UI.WebControls.WebParts; 10using System.Web.UI.HtmlControls; 11using System.Data.OleDb; 12public partial class Admin_AdminLogin : System.Web.UI.Page 13{ 14 protected void Page_Load(object sender, EventArgs e) 15 { 16 17 } 18 private void login() 19 20 {//判断登录用户 21 22 OleDbConnection con = db.con(); 23 con.Open(); 24 OleDbCommand cmd = new OleDbCommand("select * from Admin where Aname='" + this.TextBox1.Text + "'and Apwd='"+this.TextBox2.Text+"'", con); 25 OleDbDataReader sdr = cmd.ExecuteReader(); 26 if (sdr.Read()) 27 { 28 Session["aname"] = sdr["Aname"].ToString(); 29 30 Response.Write("<script language='javascript'>alert('登录成功欢迎使用本选课系统');location.href='../Admin/Index.aspx'</script>"); 31 32 } 33 else 34 { 35 36 Response.Write("<script language='javascript'>alert('用户名户密码错误请重新登录');location.href='../Admin/AdminLogin.aspx'</script>"); 37 38 39 } 40 } 41 protected void ImageButton1_Click(object sender, ImageClickEventArgs e) 42 { 43 login(); 44 45 } 46 47 48 protected void ImageButton2_Click(object sender, ImageClickEventArgs e) 49 { 50 this.TextBox1.Text = ""; 51 this.TextBox2.Text = ""; 52 this.TextBox3.Text = ""; 53 } 54} 55
还没有找到您心仪的内容?请用.net源码大搜捕
代码片断 打包下载该项目完整源码:智能选课系统源码及论坛

- 24xN.com在线帮助系统源码

- 某学院仿百渡贴吧源码

- 简历管理系统源码

- 企业资源维护综合管理系统项..

- Asp.net多线程下载示例源码

- NBear+NBear开发BBS系统源码

- 鹿茸文章管理系统(Access版)..

- ASP.NET通用权限管理系统1.0..

51Aspx.com 版权所有 CopyRight © 2000-2008. 京ICP备06046876号