private void pictureBox4_Click_1(object sender, EventArgs e) { this.Hide(); Login_SignUp lsu = new Login_SignUp(); lsu.Show(); }
private void Log_In_Click(object sender, EventArgs e) { Login_SignUp frm = new Login_SignUp(); frm.Show(); this.Hide(); }
private void button4_Click(object sender, EventArgs e) { sliderpanel.Height = button4.Height; sliderpanel.Top = button4.Top; this.Hide(); Login_SignUp frm = new Login_SignUp(); frm.Show(); }
private void button2_Click(object sender, EventArgs e) { try { byte[] img = null; FileStream fs = new FileStream(imgLoc, FileMode.Open, FileAccess.Read); BinaryReader br = new BinaryReader(fs); img = br.ReadBytes((int)fs.Length); if (textBox1.Text == "" || textBox3.Text == "" || textBox4.Text == "" || comboBox1.Text == "" || textBox5.Text == "" || textBox6.Text == "" || textBox7.Text == "" || comboBox2.Text == "") { MessageBox.Show("Please Fill Up All The Fields", "Warning", MessageBoxButtons.OK, MessageBoxIcon.Warning); } else { bool duplicate_id = false; duplicate_id = u.Duplicate_ID_Check_User(textBox3.Text); if (duplicate_id == true) { MessageBox.Show("User ID already exists.Try something Different"); } else { u.InsertUser(textBox1.Text, textBox3.Text, textBox4.Text, comboBox1.Text, textBox5.Text, textBox6.Text, textBox7.Text, comboBox2.Text, img); MessageBox.Show("Successfully Signed Up.Please wait for Admin Approval"); this.Hide(); Login_SignUp lgnp = new Login_SignUp(); lgnp.Show(); } } } catch (Exception ex) { if (ex.Message.ToString().Equals("Empty path name is not legal.")) { MessageBox.Show("Please select a valid Profile Picture", "Warning", MessageBoxButtons.OK, MessageBoxIcon.Warning); } else { //MessageBox.Show("Duplicate User ID Is Not Allowed.Try Another", "Warning", MessageBoxButtons.OK, MessageBoxIcon.Warning); MessageBox.Show("Server Error.Try Later"); } } }