Exemplo n.º 1
0
        public void deleteData()
        {
            DialogResult Result = MessageBoxAdv.Show("╓ьЁ╣Им╖║рц║рце╨╒Имаые╒м╖ " + txtStudentID.Text + " "
                                                     + txtStudentFirstName.Text + " " + txtStudentLastName.Text + " Ц╙ХкцвмДаХ ?", "бв╧бя╧║рце╨╒Имаые",
                                                     MessageBoxButtons.YesNo, MessageBoxIcon.Question, MessageBoxDefaultButton.Button2);

            if (Result == DialogResult.Yes)
            {
                database.strSQL = "DELETE FROM tblBehavior WHERE PK = " + PK;
                if (database.DoSQL(database.strSQL, "е╨╒ИмаыеЮцуб╨цИмб", true))
                {
                    var frmBehaviorList = new frmBehaviorList();
                    frmBehaviorList.RetrieveData();
                    Close();
                }
            }
        }
Exemplo n.º 2
0
        public void deleteData(string txt1, string txt2, string TeacherID)
        {
            DialogResult Result = MessageBoxAdv.Show("¤Ø³µéͧ¡ÒáÒÃź¢éÍÁÙŢͧ " + txt1 + " "
                                                     + txt2 + " ãªèËÃ×ÍäÁè ?", "Â×¹Âѹ¡ÒÃź¢éÍÁÙÅ",
                                                     MessageBoxButtons.YesNo, MessageBoxIcon.Question, MessageBoxDefaultButton.Button2);

            if (Result == DialogResult.Yes)
            {
                string strSQL1 = "DELETE FROM tblUser WHERE TeacherID = " + TeacherID;
                string strSQL2 = "DELETE FROM tblUser WHERE TeacherID = " + TeacherID;

                if (database.DoSQL(strSQL1) && database.DoSQL(strSQL2, "ź¢éÍÁÙÅàÃÕºÃéÍÂ", true))
                {
                    var frmBehaviorList = new frmBehaviorList();
                    frmBehaviorList.RetrieveData();
                    Close();
                }
            }
        }
 public void deleteData()
 {
     if (btnDelete.Enabled == true)
     {
         DialogResult Result = MessageBoxAdv.Show("�س��ͧ��á��ź�����Ţͧ " + txtStdID.Text + " "
                                                  + txtStdFirstName.Text + " " + txtStdLastName.Text + " ��������� ?", "�׹�ѹ���ź������",
                                                  MessageBoxButtons.YesNo, MessageBoxIcon.Question, MessageBoxDefaultButton.Button2);
         if (Result == DialogResult.Yes)
         {
             database.strSQL = "DELETE FROM tblStudent WHERE std_ID = " + stdID;
             if (database.DoSQL(database.strSQL, "ź���������º����", true))
             {
                 var frmBehaviorList = new frmBehaviorList();
                 frmBehaviorList.RetrieveData();
                 Close();
             }
         }
     }
     return;
 }
Exemplo n.º 4
0
        private void BehaviorList_Click(object sender, EventArgs e)
        {
            var frmBehaviorList = new formData.frmBehaviorList();

            loadForm.showWaitForm(frmBehaviorList);
        }