Esempio n. 1
0
 private void butDelete_Click(object sender, EventArgs e)
 {
     if (TaskNoteCur.IsNew)
     {
         DialogResult = DialogResult.Cancel;
         return;
     }
     if (!MsgBox.Show(this, MsgBoxButtons.OKCancel, "Delete?"))
     {
         return;
     }
     TaskNotes.Delete(TaskNoteCur.TaskNoteNum);
     DialogResult = DialogResult.OK;
 }
Esempio n. 2
0
 private void butDelete_Click(object sender, EventArgs e)
 {
     if (!MsgBox.Show(this, MsgBoxButtons.OKCancel, "Delete?"))
     {
         return;
     }
     if (TaskNoteCur.IsNew)
     {
         DialogResult = DialogResult.Cancel;
         Close();                //Needed because the window is called as a non-modal window.
         return;
     }
     TaskNotes.Delete(TaskNoteCur.TaskNoteNum);
     DialogResult = DialogResult.OK;
     OnEditComplete();
     Close();            //Needed because the window is called as a non-modal window.
 }
Esempio n. 3
0
 private void butDelete_Click(object sender, EventArgs e)
 {
     if (!MsgBox.Show(this, MsgBoxButtons.OKCancel, "Delete?"))
     {
         return;
     }
     if (TaskNoteCur.IsNew)
     {
         DialogResult = DialogResult.Cancel;
         Close();                //Needed because the window is called as a non-modal window.
         return;
     }
     TaskNotes.Delete(TaskNoteCur.TaskNoteNum);
     DialogResult = DialogResult.OK;
     OnEditComplete();
     Tasks.TaskEditCreateLog(Permissions.TaskNoteEdit, Lan.g(this, "Deleted note from task"), Tasks.GetOne(TaskNoteCur.TaskNum));
     Close();            //Needed because the window is called as a non-modal window.
 }