private static void OnDayChanged(DependencyObject obj, DependencyPropertyChangedEventArgs e) { UTimeControl control = obj as UTimeControl; DayEnum d = (DayEnum)e.NewValue; control.cbxDay.Content = CUtil.DayEnumToString(d); control.grbBox.Header = CUtil.DayEnumToString(d); }