You can add a custom onEventMoving handler:
dp.onEventMoving = function(args) {
if (args.end > dp.visibleEnd()) {
args.left.enabled = true;
args.left.html = "You can't drag the event out of the visible range";
args.right.enabled = true;
args.allowed = false;
}
if (args.start < dp.visibleStart()) {
args.right.enabled = true;
args.right.html = "You can't drag the event out of the visible range";
args.left.enabled = true;
args.allowed = false;
}
};
See also:
http://api.daypilot.org/daypilot-scheduler-oneventmoving/