We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

Is there and event for month change on Schedule Control?

Thread ID:





79021 Jan 16,2009 10:23 AM Jan 23,2009 01:33 AM Windows Forms 4
Tags: ScheduleControl
Peter Titus
Asked On January 16, 2009 10:23 AM

I am trying to capture when a user changes the month on the caption panel on the schedule control. Is there an event that captures that? I have been unable to find anything. Any help would be appreciated.


Rajadurai C [Syncfusion]
Replied On January 19, 2009 08:52 AM

Hi Peter,

Thanks for your interest in Syncfusion products.

Apologies for the delay.

You can track the change in text in caption panel by handling the following event.

this.scheduleControl1.HeaderLabel.TextChanged += new EventHandler(HeaderLabel_TextChanged);

void HeaderLabel_TextChanged(object sender, EventArgs e)


Peter Titus
Replied On January 19, 2009 09:48 AM

That worked to handle the text change. Now I am trying to pull the current date on the control. I am using ScheduleControl1.Calendar.DateValue, but that doesn't seem to be consistant with what the text is showing. Is there a better date to use? Or do I need to parse the header text? What happens now is that the text doesn't change on the first click on the left arrow, but the dateValue does. So if you click twice, the dateValue goes back two months but the text only goes back one. Any help is appreciated. Or if you want me to move this over to Direct-Trac, let me know. It seems like it might be getting bigger than a quick forum question.

Peter Titus
Replied On January 20, 2009 12:51 PM

I figured out how to manually do this via the following code. Let me know if you had something better, but this seems to work.

Dim StartDate As New Date(Me.ScheduleControl1.Calendar.DateValue.Year, Me.ScheduleControl1.Calendar.DateValue.Month, 1)
Dim EndDate As Date = StartDate.AddMonths(1)

While StartDate < EndDate
StartDate = StartDate.AddDays(1)
End While

Jisha Joy [Syncfusion]
Replied On January 23, 2009 01:33 AM

Hi Perter,

Thank you for your update. Thanks for sharing information with us.



This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.