Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
415
Attemping to create custom control... One simple step left - please help
posted

I am attempting to override the UltraCalendarCombo so that when a user clicks a date, that date toggles on or off, and an unlimited amount of dates can be selected. I have gotten everything working except I can't seem to figure out how to prevent the datepicker from closing when a date is clicked. 

Of course just my luck there is a BeforeDrop and AfterDrop but only an AfterClosing, no before. Here is my Code so far:

 

 

public class MyDatePicker : UltraCalendarCombo {

      StreamWriter sw;

      public MyDatePicker() {

      }

      protected override void CalendarInfoChanged(CalendarInfoChangedEventArgs e) {

 

         if( e.PropChangeInfo.PropId.ToString() != "ActiveDay" ) {

               base.CalendarInfoChanged( e );

         }

         else {

            UltraCalendarInfo info = e.PropChangeInfo.Source as UltraCalendarInfo;

            DateTime newDate = info.ActiveDay.Date;

            UltraCalendarLook calendarLook = this.CalendarLook;

            DayLook dayLook = calendarLook.GetDayLook( newDate, true );

            dayLook.Appearance.BackColor = Color.Aqua;

         }

      }

 

 

Strangely enough, calling this.PerformAction( Infragistics.Win.UltraWinSchedule.CalendarCombo.CalendarComboAction. CancelCloseUp ); does not seem to help.

Parents Reply Children
No Data