Example #1
0
        private void button1_Click(object sender, RoutedEventArgs e)
        {
            string msg = GroupTextBox.Text;

            GroupRichTextBox.AppendText(msg + '\n');
            GroupTextBox.Clear();
        }
Example #2
0
        private void GroupTextBox_KeyDown(object sender, System.Windows.Input.KeyEventArgs e)
        {
            string msg = GroupTextBox.Text;

            if (e.Key.Equals(Keys.Enter))//如果输入的是回车键
            {
                GroupRichTextBox.AppendText(msg + '\n');
                GroupTextBox.Clear();
            }
        }
 private void ClearForm()
 {
     firstNameTextBox.Clear();
     secondNameTextBox.Clear();
     lastNameTextBox.Clear();
     SpecialtyTextBox.Clear();
     FacultyTextBox.Clear();
     FNumTextBox.Clear();
     CourseTextBox.Clear();
     StreamTextBox.Clear();
     GroupTextBox.Clear();
 }