private void btnModify_Click(object sender, EventArgs e)
 {
     if (selectedRowIndex < 0)
     {
         string str = WorkingContext.LangManager.GetString("frmRegOverTime_Edit_messa");
         string str1 = WorkingContext.LangManager.GetString("frmListRegRest_Edit_Title");
         //MessageBox.Show("Bạn chưa chọn nhân viên nào!", "Sửa đăng ký nghỉ của nhân viên", MessageBoxButtons.OK,  MessageBoxIcon.Exclamation);
         MessageBox.Show(str, str1, MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
         return;
     }
     else
     {
         frmRegRestEmployee regRestEmployee = new frmRegRestEmployee();
         regRestEmployee.UPDATE = true;
         regRestEmployee.RestEmployeeDataSet = dsRegRestEmployee;
         regRestEmployee.CurrentRestEmployee = selectedRowIndex;
         regRestEmployee.ShowDialog();
         PopulateRestEmployee();
     }
     selectedRowIndex = -1;
     tableModel1.Selections.Clear();
 }
 private void lvwRestEmployee_MouseDown(object sender, MouseEventArgs e)
 {
     if (e.Button == MouseButtons.Left && e.Clicks == 2)
     {
         if (lvwRestEmployee.SelectedItems.Length > 0)
         {
             frmRegRestEmployee frm = new frmRegRestEmployee();
             frm.RestEmployeeDataSet = dsRegRestEmployee;
             frm.CurrentRestEmployee = selectedRowIndex;
             frm.ShowDialog(this);
             PopulateRestEmployee();
         }
         selectedRowIndex = -1;
         tableModel1.Selections.Clear();
     }
 }
 private void btnAdd_Click(object sender, EventArgs e)
 {
     frmRegRestEmployee restEmployee = new frmRegRestEmployee();
     restEmployee.RestEmployeeDataSet = dsRegRestEmployee;
     restEmployee.ShowDialog();
     PopulateRestEmployee();
     selectedRowIndex = -1;
     tableModel1.Selections.Clear();
 }