示例#1
0
        private void DBScanFormOk_Click(object sender, EventArgs e)
        {
            if (ButtonGetEpsMinptsClicked != null)
            {
                if ((EpsBox.Text != "") && (PtsBox.Text != ""))
                {
                    ButtonGetEpsMinptsClicked(sender, e);
                    this.Close();
                }

                if (EpsBox.Text == "")
                {
                    MessageBox.Show("Please input value Esp", "Esp not valid");
                    EpsBox.Focus();
                }
                if (PtsBox.Text == "")
                {
                    MessageBox.Show("Please input value Minpts", "Minpts not valid");
                    PtsBox.Focus();
                }
            }
        }
示例#2
0
 private void EpsBox_KeyPress(object sender, KeyPressEventArgs e)
 {
     if (ButtonGetEpsMinptsClicked != null)
     {
         if (e.KeyChar == 13)
         {
             if (EpsBox.Text == "")
             {
                 MessageBox.Show("Please input value Esp", "Esp not valid");
                 EpsBox.Focus();
             }
             if (PtsBox.Text == "")
             {
                 MessageBox.Show("Please input value Minpts", "Minpts not valid");
                 PtsBox.Focus();
             }
             if ((EpsBox.Text != "") && (PtsBox.Text != ""))
             {
                 ButtonGetEpsMinptsClicked(sender, e);
                 this.Close();
             }
         }
     }
 }