Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- private int monthIndex = DateTime.Today.Month - 1;
- public int MonthIndex
- {
- get { return monthIndex; }
- set
- {
- if (monthIndex != value)
- {
- monthIndex = value;
- RaisePropertyChanged("MonthIndex");
- }
- }
- }
- private int _dayIndex = DateTime.Today.Day - 1;
- <ComboBox Name="cboDay"
- ItemsSource="{Binding DaysList, Mode=OneTime}"
- DisplayMemberPath="fltDay"
- SelectedIndex="{Binding DayIndex, Mode=TwoWay}"
- IsEditable="True" />
- public ObservableCollection<Day> DaysList { get; set; }
- private int _dayIndex;
- public int DayIndex
- {
- get
- {
- // perform some calculation logic;
- return _dayIndex;
- }
- set
- {
- if (_dayIndex != value)
- {
- _dayIndex = value;
- RaisePropertyChanged("DayIndex");
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement