private void CheckBox_Checked(object sender, RoutedEventArgs e) { configViewModel = this.DataContext as ConfigSettingViewModel; if (configViewModel != null) { CheckBox chk = (CheckBox)sender; configViewModel.CheckCheckBoxValueChange(chk.Name, chk.IsChecked); } }
private void TextBox_TextChanged(object sender, TextChangedEventArgs e) { configViewModel = this.DataContext as ConfigSettingViewModel; if (configViewModel != null) { TextBox chk = (TextBox)sender; if(chk.Name != null && !chk.Name.Equals("")){ configViewModel.CheckTextValueChange(chk.Name,chk.Text); } } }
private void RadioButton_Click(object sender, RoutedEventArgs e) { configViewModel = this.DataContext as ConfigSettingViewModel; if (configViewModel != null) { RadioButton chk = (RadioButton)sender; string tag = string.Format("{0}", chk.Tag); if (tag != null && !tag.Equals("")) { configViewModel.CheckRadioButtonValueChange(tag, chk.Name); } } }