How to manage the calendar events