Mike,
You can specify the initial selection using selectionDay property of DayPilot.Navigator. If not specified, it will use today's date.
var nav = new DayPilot.Navigator("nav");
nav.selectionDay = DayPilot.Date.today().addDays(7); // next week
nav.onTimeRangeSelected = function(args) {
dp.startDate = args.start;
dp.update();
};
// ...
nav.init();
When initializing the Calendar, make sure that you are using this date as startDate:
var dp = new DayPilot.Calendar("dp");
dp.startDate = nav.selectionDay;
// ...
dp.init();
All subsequent changes of the Navigator selection will be mapped to the Calendar using nav.onTimeRangeSelected event handler. So the other option is to call select() after both components are initialized:
var nav = new DayPilot.Navigator("nav");
nav.onTimeRangeSelected = function(args) {
dp.startDate = args.start;
dp.update();
};
// ...
nav.init();
var dp = new DayPilot.Calendar("dp");
dp.startDate = nav.selectionDay;
// ...
dp.init();
nav.select(DayPilot.Date.today().addDays(7));
Please let me know if it didn't help.