상속: System.EventArgs
예제 #1
0
        private void daynew_Selected(object sender, DaySelectArgs e)
        {
            GeneralDay.Selected -= daynew_Selected;

            Day day = e.day;

            if (lastDay != null)
            {
                if (lastDay != day)
                {
                    for (int i = 0; i < Days.Count; i++)
                    {
                        if (lastDay.SelectedDate.Month == Days[i].SelectedDate.Month)
                        {
                            if (lastDay.SelectedDate.Day == Days[i].SelectedDate.Day)
                            {
                                lastDay = Days[i];
                                Days.RemoveAt(i);
                                Days.Insert(i, lastDay);
                            }
                        }
                    }
                }
            }
            lastDay = day;
            OnDaySelected(day);
        }
        private void daynew_Selected(object sender, DaySelectArgs e)
        {
            GeneralDay.Selected -= daynew_Selected;

            Day day = e.day;
            if (lastDay != null)
            {
                if (lastDay != day)
                {
                    for (int i = 0; i < Days.Count; i++)
                    {
                        if (lastDay.SelectedDate.Month == Days[i].SelectedDate.Month)
                            if (lastDay.SelectedDate.Day == Days[i].SelectedDate.Day)
                            {
                                lastDay = Days[i];
                                Days.RemoveAt(i);
                                Days.Insert(i, lastDay);
                            }
                    }
                }
            }
            lastDay = day;
            OnDaySelected(day);
        }