Export (0) Print
Expand All
Expand Minimize

Application.TimelineInsertTask Method (Project)

When the Timeline view is selected, displays the Task Information dialog box, and then inserts a new task into the project and adds the task to the Timeline view.

Version Added: Project 2010

expression .TimelineInsertTask(Type)

expression An expression that returns an Application object.

Parameters

Name

Required/Optional

Data Type

Description

Type

Required

PjTimelineInsertTaskType

Specifies the type of task; that is, whether the task is a regular task, a milestone, or a callout task. Can be one of the following PjTimelineInsertTaskType constants: pjTimelineInsertTask, pjTimelineInsertMilestone, or pjTimelineInsertCalloutTask. Any of the task types can be manually or automatically scheduled.

Return Value

Boolean

The TimelineInsertTask method shows a manually scheduled or automatically scheduled task in the Task Information dialog box, depending on the type of task shown in the New Tasks section of the Project status bar.

If the user cancels the Task Information dialog box, TimelineInsertTask returns False.

Note Note

The Display on Timeline check box in the Task Information dialog box is clear. The TimelineInsertTask method adds a task to the timeline whether the check box is checked or clear.

The TimelineInsertTask method corresponds to the Task, Callout Task, and Milestone commands in the Insert group on the Format tab on the Ribbon. The Format tab displays the Insert group when the Timeline view is selected. If the Timeline view is not selected, the TimelineInsertTask method results in error 1100, "The method is not available in this situation."

If the Project status bar shows New Tasks: Manually Scheduled, the following statement displays the Task Information dialog box, which prompts the user to name a manually scheduled task. The default start date is the project start date. When the user clicks OK, Project inserts the task in the Gantt chart and shows the new task on the timeline, with the task information in a callout box attached to the timeline.

Application.TimelineInsertTask Type:=pjTimelineInsertCalloutTask
Show:
© 2014 Microsoft