protected void Button1_Click(object sender, EventArgs e) { EmpProps p = new EmpProps(); p.E_id = txt_eid.Text; p.E_name = txt_name.Text; p.E_cell = txt_cell.Text; p.E_address = txt_address.Text; p.E_email = txt_email.Text; p.E_password = txt_password.Text; EmpBLL emp = new EmpBLL(); if (emp.insertEmpBLL(p)) { txt_eid.Text = ""; txt_name.Text = ""; txt_cell.Text = ""; txt_address.Text = ""; txt_email.Text = ""; txt_password.Text = ""; Response.Write("<script>alert('Record Inserted Successfull')</script>"); } else { Response.Write("<script>alert('Record Inserted Unsuccessfull')</script>"); } }
private void save_Click(object sender, EventArgs e) { EmpProps p = new EmpProps(); p.E_id = txt_eid.Text; p.E_name = txt_name.Text; p.E_cell = txt_cell.Text; p.E_address = txt_address.Text; EmpBLL emp = new EmpBLL(); if (emp.insertEmpBLL(p)) { MessageBox.Show("Record Inserted Successfully"); txt_eid.Text = ""; txt_name.Text = ""; txt_cell.Text = ""; txt_address.Text = ""; } else { MessageBox.Show("Record Inserted Unsuccessfull"); } }