Application.OptionsSchedule method (Project)

Sets scheduling options.

Syntax

expression. OptionsSchedule( _ScheduleMessages_, _StartOnCurrentDate_, _AutoLink_, _AutoSplit_, _CriticalSlack_, _TaskType_, _DurationUnits_, _WorkUnits_, _AutoTrack_, _SetDefaults_, _AssignmentUnits_, _EffortDriven_, _HonorConstraints_, _ShowEstimated_, _NewTasksEstimated_ )

expression A variable that represents an Application object.

Parameters

Name Required/Optional Data type Description
ScheduleMessages Optional Variant Boolean. True if messages display when scheduling problems occur; otherwise, False.
StartOnCurrentDate Optional Boolean True if new tasks start on the current date. False if new tasks start on the project start date (projects scheduled from the start date) or on the project finish date (projects scheduled from the finish date).
AutoLink Optional Boolean True if tasks are automatically linked; otherwise, False.
AutoSplit Optional Boolean True if tasks in progress are automatically split; otherwise, False.
CriticalSlack Optional Variant The maximum amount of slack allowed for critical tasks.
TaskType Optional Long The default type for new tasks. Can be one of the PjTaskFixedType constants.
DurationUnits Optional Long The default duration unit for tasks. Can be one of the PjUnit constants.
WorkUnits Optional Long The default work unit for resource assignments. Can be one of the PjUnit constants.
AutoTrack Optional Boolean True if task tracking fields automatically update resource assignments; otherwise, False.
SetDefaults Optional Boolean True if the values specified for all arguments except ScheduleMessages and AssignmentUnits become the defaults for new project files; otherwise, False.
AssignmentUnits Optional Long Specifies how assignment units should display. Can be one of the PjAssignmentUnit constants.
EffortDriven Optional Boolean True if new tasks are effort-driven; otherwise, False.
HonorConstraints Optional Boolean True if tasks honor their constraint dates; otherwise, False.
ShowEstimated Optional Boolean True if task durations in new projects are displayed with the estimated character; otherwise, False.
NewTasksEstimated Optional Boolean True if new tasks in the active project have estimated durations; otherwise, False.

Return value

Boolean

Remarks

If an argument is omitted, its default value is specified by the current setting on the Schedule tab of the Project Options dialog box.

Using the OptionsSchedule method without specifying any arguments displays the Project Options dialog box.

Example

The following example enables messages to be displayed when scheduling problems occur, schedules new tasks to start on the current date, and sets the default duration unit for tasks to a week.

Sub Options_Schedule() 
 OptionsSchedule ScheduleMessages:=True, StartOnCurrentDate:=True, DurationUnits:=pjWeek 
End Sub

Support and feedback

Have questions or feedback about Office VBA or this documentation? Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.