search envelope-o feed check
Home Unanswered Active Tags New Question
user comment-o

how to add Switching Day/Week View

Related article: HTML5/JavaScript Event Calendar (Open-Source)
Asked by Max
5 years ago.

how to add Switching Day/Week View just link in AngularJS Event Calendar (Open-Source)

Answer posted by Dan Letecky [DayPilot]
5 years ago.

To switch the view, you just need to change the viewType value and call update(), like this:

Switch to day view:

dp.viewType = "Day";
dp.update();

Switch to week view:

dp.viewType = "Week";
dp.update();

Comment posted by Max
5 years ago.

i see i am not a programmer, could you please write complete code.

Answer posted by Anonymous
5 years ago.

var dp = new DayPilot.Scheduler("dp");
dp.viewType = "Days";
dp.days = 30;
dp.update();
dp.init();

This question is more than 1 months old and has been closed. Please create a new question if you have anything to add.