protected void Page_Load(object sender, EventArgs e) { //Panel1.Visible = false; Session["m1"] = ""; GridView3.Visible = false; GridView2.Visible = false; GridView1.Visible = false; GridView4.Visible = false; // Session["uid"] = 0; //GridView1.Visible = false; //GridView2.Visible = false; try { if (!IsPostBack) { SqlDataReader dr = BookOrder.Getview("SELECT Bookname,Publication,Authername1 FROM bookview"); while (dr.Read()) { DropDownList1.Items.Add(dr.GetValue(0).ToString()); DropDownList3.Items.Add(dr.GetValue(1).ToString()); DropDownList2.Items.Add(dr.GetValue(2).ToString()); } } } catch { } }
protected void LinkButton2_Click(object sender, EventArgs e) { if (TextBox1.Text != "") { try { SqlDataReader dr1 = BookOrder.Getview("SELECT Passwords FROM Admin1 where UserName='******'"); while (dr1.Read()) { Label7.Text = dr1.GetValue(0).ToString(); } if (Label7.Text == TextBox2.Text) { Response.Redirect("~/Admin/Memberorderview.aspx"); } else { Label8.Text = "ReEnter Password And UserName"; } } catch { Label8.Text = "ReEnter Password And UserName"; } } else { Label8.Text = "Enter userName"; } }
protected void ImageButton2_Click(object sender, ImageClickEventArgs e) { SqlDataReader dr1 = BookOrder.Getview("SELECT Description FROM Order1 where Orderid='" + TextBox1.Text.ToString() + "' and Memberid='" + Session["uid"].ToString() + "' "); while (dr1.Read()) { Label10.Text = dr1.GetValue(0).ToString(); } }
protected void LinkButton2_Click(object sender, EventArgs e) { try { SqlDataReader dr1 = BookOrder.Getview("SELECT Memberid from Member where UserName='******'"); while (dr1.Read()) { //Label3.Text = dr1.GetValue(0).ToString(); Session["mid1"] = dr1.GetValue(0).ToString(); TextBox1.Text = dr1.GetValue(0).ToString(); } Response.Redirect("~/Admin/lendpage.aspx"); } catch { } }
protected void Page_Load(object sender, EventArgs e) { try { if (!IsPostBack) { SqlDataReader dr = BookOrder.Getview("SELECT Username FROM Member"); while (dr.Read()) { DropDownList1.Items.Add(dr.GetValue(0).ToString()); } } } catch { } }
protected void LinkButton5_Click(object sender, EventArgs e) { if (TextBox1.Text != "") { try { SqlDataReader dr1 = BookOrder.Getview("SELECT Firstname,Username,Password,Memberid FROM Member where UserName='******'"); while (dr1.Read()) { //Label3.Text = dr1.GetValue(0).ToString(); Session["cname"] = dr1.GetValue(0).ToString(); Session["un"] = dr1.GetValue(1).ToString(); Label7.Text = dr1.GetValue(2).ToString(); Session["uid"] = dr1.GetValue(3).ToString(); } if (Label7.Text == TextBox2.Text) { Session["m2"] = "Dear : " + Session["cname"] + "your Are Order This Book .if you Lend The Book Click to Conform your Lending Else Click to Reorder "; Session["m1"] = "Dear : " + Session["cname"] + " Wait A Few Secound We Will Send A Reply For Your Lend"; //Response.Redirect("~/Customer/OrderStatus.aspx"); Response.Redirect("~/Member site/Membership.aspx"); // Master.logMessage = "LogOff" + "(" + TextBox1.Text.ToString() + ")"; } else { Label8.Text = "ReEnter Password And UserName"; } } catch { Label8.Text = "ReEnter Password And UserName"; } } else { Label8.Text = "Enter userName"; } }
protected void Button2_Click(object sender, EventArgs e) { if (TextBox1.Text != "") { try { SqlDataReader dr1 = BookOrder.Getview("SELECT Firstname,Username,Password,Memberid FROM Member where UserName='******'"); while (dr1.Read()) { Session["cname"] = dr1.GetValue(0).ToString(); Session["un"] = dr1.GetValue(1).ToString(); Label7.Text = dr1.GetValue(2).ToString(); Session["pw"] = dr1.GetValue(2).ToString(); Session["uid"] = dr1.GetValue(3).ToString(); } if (Label7.Text == TextBox2.Text) { Session["m2"] = "Dear : " + Session["cname"] + "You Have Not Orders Visit to Book Order Pages"; Response.Redirect("~/Member site/Membership.aspx"); Session["ordernumber"] = 0; Panel1.Visible = false; } else { Label6.Text = "ReEnter Password And UserName"; } } catch { Label6.Text = "Reenter Password And UserName"; } } else { Label6.Text = "Enter userName"; } }