private void btnSave_Click(object sender, RoutedEventArgs e) { if ((txtWord.Text != "") && (txtMeaning.Text != "") && (cmbDiff.SelectedIndex != 0)) { DAWords dawords = new DAWords(); dawords.InsertWord(txtWord.Text, txtMeaning.Text, txtWord.Text.ToLower()[0].ToString(), diffGlob.ID); txtMeaning.Clear(); txtWord.Clear(); txtWord.Focus(); // cmbDiff.SelectedIndex = 0; FillCmbData(); } else { MessageBox.Show("אחד מהנתונים לא תקין אנא בדוק"); } }