Ejemplo n.º 1
0
 private void btnEdit_Click(object sender, EventArgs e)
 {
     frmMemberAdd frm = new frmMemberAdd("EDIT");
     frm.txtID.Visible = true;
     frm.txtID.Text = dgvView.Rows[dgvView.CurrentRow.Index].Cells["Mem_ID"].Value.ToString().Trim();
     frm.txtName.Text = dgvView.Rows[dgvView.CurrentRow.Index].Cells["Mem_Name"].Value.ToString().Trim();
     frmMemberAdd.Shere = dgvView.Rows[dgvView.CurrentRow.Index].Cells["Share_Member"].Value.ToString().Trim();
     frm.txtTel.Text = dgvView.Rows[dgvView.CurrentRow.Index].Cells["Phone"].Value.ToString().Trim();
     frmMemberAdd.Status = dgvView.Rows[dgvView.CurrentRow.Index].Cells["Status"].Value.ToString().Trim();
     frm.txtAddress.Text = dgvView.Rows[dgvView.CurrentRow.Index].Cells["Address"].Value.ToString().Trim();
     frm.ShowDialog();
     btnSearch_Click(sender, e);
 }
Ejemplo n.º 2
0
 private void btnAdd_Click(object sender, EventArgs e)
 {
     var frm = new frmMemberAdd("INSERT");
     frm.ShowDialog();
     btnSearch_Click(sender, e);
 }