Tasks and Calendars

Tasks with Calendars

The Task class exposes the Calendar property, used to set or get the calendar associated with a task. This property accepts or returns an object of com.aspose.tasks.Calendar class.

To create a calendar for a task in Microsoft Project:

  1. Open a project in Microsoft Project.
  2. On the Project menu, select Change Working Times, then Create New Calendar.
  3. To assign the calendar to a task, double-click the task in the Task Entry form.
  4. Select the Advanced tab.

The Change Working Time dialog showing a custom-made calendar

changing working time in resource calendar in Microsoft Project

Setting Task Calendar

Create a standard calendar and create a task. Assign the Calendar to the task.

Getting Task Calendar

Get a task calendar by traversing the tasks in a project.