activeproject.tasks(index) using name RRS feed

  • Question


    I am trying to use the activeproject.tasks() function by using the task name as the index key.  I can't seem to get it right.

    The text below suggests that this should be possible... (It is from Microsoft documentation).

    Using the Task Object

    Use Tasks(Index), where Index is the task index number or task name, to return a single Task object. The following example prints the names of every resource assigned to every task in the active project.

    I am using Microsoft Project 2016.  Has this functionality changed?

    Tuesday, June 13, 2017 10:18 PM

All replies

  • dddorsey,

    It works fine with either the task ID or name as the index. However, remember that when you use the name, it is a string and therefore must be in quotes. For example

    ActiveProject.Tasks("task a")

    Hope this helps.


    Tuesday, June 13, 2017 11:07 PM