Checks if the current range ends at the same time as the specified range.
Namespace: MindFusion.Scheduling
File: TimeRange.js
JavaScript Copy Code |
---|
function sameEnd (range) |
Boolean. true if the current range ends at the same time with the specified range; otherwise false.
The following code creates a range at the end of December and checks if the current calendar selection ends at the same time as the holiday range:
JavaScript Copy Code |
---|
var p = MindFusion.Scheduling; // create a new instance of the calendar var selectedRange = calendar.selection.getRange(); var holidayStart = p.DateTime.fromDateParts(2018, 12, 20); var holidayRange = new TimeRange(holidayStart, holidayEnd); if (selectedRange.sameEnd(holidayRange)) |