Macro to Update Status Manager field on new Projects created using a Template? RRS feed

  • Question

  • Our organization centrally creates new Projects using a template.  The problem with this is that the creator of the Project is almost never the Owner of the Project but gets assigned as the Status Manager of all the Tasks upon Project creation by default.  The creator then has to go into the Project as a delegate of the Owner, create a dummy Task as the Owner, then open the Project in Project Desktop and reassign all the Tasks to the Owner (and then delete the dummy task).

    Is there a way to default the Status Manager field to the Owner of the Project upon creation, instead of it being the creator of the Project?  From what I've read, there isn't.  But some posts have alluded to being able to do this via a macro but i can't seem to find any further details beyond this.

    Friday, October 13, 2017 11:39 PM

All replies

  • Hi,

    as you wrote, it is not possible to change the default Status Manager. But you could follow this process:

    • Creator creates Project
    • Creator changes Owner
    • Owner opens project and run the following macro
    Sub StatusManager()
    Dim P As Project
    Dim T As Task
    Dim UpdateProjectOwner As String
    Set P = ActiveProject
    On Error Resume Next
    UpdateProjectOwner = MsgBox(Prompt:="Are you the Project Owner and want to update Status Manager for all tasks?", Buttons:=vbYesNo, Title:="Status Manager")
    If UpdateProjectOwner = vbYes Then
        For Each T In pj.Tasks
            If Not T Is Nothing Then
                If Not T.Summary Then
                    If T.StatusManagerName <> pj.ProjectSummaryTask.StatusManagerName Then
                        T.StatusManagerName = pj.ProjectSummaryTask.StatusManagerName
                    End If
                End If
            End If
        Next T
    End If
    End Sub


    Saturday, October 14, 2017 7:43 AM