Search
Calendar.visibleDateChanged Event
See Also
 






Raised when the calendar date is changed.

Namespace: MindFusion.Scheduling
File: Calendar.js

 Syntax

JavaScript  Copy Code

EventDispatcher visibleDateChanged

 Event Data

The event handler method receives the following arguments:
sender
A Calendar instance, which is the source of the event. This object will be passed to the handler function as the first argument.
args
A DateChangedEventArgs instance, which contains event data. This object will be passed to the handler function as the second argument.

 Example

The following example attaches a handler to the visibleDateChanged event of a calendar. In the handler method we check if the new date starts after the 19th day of the month.

JavaScript  Copy Code

var p = MindFusion.Scheduling;

// attach a handler - the visible date of the calendar has changed.
calendar.visibleDateChanged.addEventListener(handleVisibleDateChanged);

function handleVisibleDateChanged(sender, args) {
          if(args.newDate.day > 19)
            //do something
            ...............
     
}

 See Also