protected void bt_Yes_Click(object sender, EventArgs e) { BLL.SystemInfo bll = new BLL.SystemInfo(); Model.SystemInfo model = new Model.SystemInfo(); string UserSys, CourseSys, SN; UserSys = Session["UserSys"].ToString(); CourseSys = Session["CourseSys"].ToString(); SN = Session["SN"].ToString(); Session.RemoveAll(); model.HardInfo = "1"; model.UserSys = UserSys; model.CourseSys = CourseSys; model.SN = SN; model.sPassword = tb_Password.Text.Trim(); bll.Add(model); }
protected void Page_Load(object sender, EventArgs e) { if (!Page.IsPostBack) { try { BLL.SystemInfo bll = new BLL.SystemInfo(); List <Model.SystemInfo> list = new List <Model.SystemInfo>(); list = bll.GetList(); if (list.Count > 0) { gv01.DataSource = list; gv01.DataBind(); lb_Msg.Text = "您已成功安装过此系统!"; bt_Yes.Enabled = false; } else { } } catch { } } }