none
how to update all projects data (checkout-edit-save&publish-checkin)? RRS feed

  • General discussion

  • Hi every one,

    we have more that 400 projects in pwa and it will take too much time to update status date for all of them one by one mounthly

    so I'm looking for a solution (probably VBA) for opening all projects and set the status date to a specified value and save & publish then check-in all of them.

    is there any way to get it done?

    thanks for any help

    Sunday, December 22, 2013 12:04 PM

All replies

  • Hi, 

    You can publish the project either from PSI in which you can write your business logic and publish the project plan via using project server pre defined methods.

    http://msdn.microsoft.com/en-us/library/office/gg177147.aspx

    You can also use Project server power shell command to publish the projects 

    you can download script from link.

    http://gallery.technet.microsoft.com/projectserver/Server-2010-Publish-all-45ba385b

    https://pwmather.wordpress.com/2012/05/31/updated-publish-all-projects-in-projectserver-using-powershell-msproject-ps2010-sp2010/

    For doing same via VBA i got  http://www.epmcentral.com/pjadmin/vbasavefiles.php

    check it .. 


    kirtesh


    • Edited by Kirteshtiw Sunday, December 22, 2013 1:43 PM
    Sunday, December 22, 2013 1:23 PM
  • Hi, 

    You can publish the project either from PSI in which you can write your business logic and publish the project plan via using project server pre defined methods.

    http://msdn.microsoft.com/en-us/library/office/gg177147.aspx

    You can also use Project server power shell command to publish the projects 

    https://pwmather.wordpress.com/2012/05/31/updated-publish-all-projects-in-projectserver-using-powershell-msproject-ps2010-sp2010/

    For doing same via VBA i got  http://www.epmcentral.com/pjadmin/vbasavefiles.php

    check it .. 


    kirtesh

    thanks for your quick reply

    unfortunately I don't have any knowledge of programming so I perefer to use VBA in client project professional

    your VBA link is about :"Scenario:  If you want to save multiple project plans from project server to your local machine. To do this, you have to open each project plan and need to save individually to local machine. " so it can't help me.

    I want to save and publish projects in project server 2010

    Sunday, December 22, 2013 1:56 PM
  • Hi,

    You can download script from MSDN and use it to publish all your project IN this you need not to do any thing this script is based on powershell.

    http://gallery.technet.microsoft.com/projectserver/Server-2010-Publish-all-45ba385b


    kirtesh

    Sunday, December 22, 2013 1:59 PM
  • Hi,

    You may be able to do this using the Bulk Edit solution starter for 2010: http://archive.msdn.microsoft.com/P2010SolutionStarter

    I don't know for certain if it supports the Status Date field, but if it does then that should solve you problem.

    If you're using 2013 there is an App that will do that also (ahem - self interest disclaimer): Bulk Edit App.


    Martin Laukkanen (Project Server Blog - www.nearbaseline.com/blog)

    Sunday, December 22, 2013 11:00 PM
  • You can build a user form in VBA

    I made one that has 12 text boxes with project names. It is used to open and close and republish projects to current date as status date but you could just as easily set that date to something specific.

    Dim controlplanname
    If TextBox1.TextLength <> 0 Then
        controlplanname = "<>\" & Trim(TextBox1.Text)
        FileOpenEx Name:=controlplanname, ReadOnly:=False
        Macro Name:="AfterAcceptControlPlanUpdates_Close"
    End If

    Sub abAfterAcceptControlPlanUpdates_Close()
    ' this is a first attempt at a one button macro
    ' after countless control plans are opened from the web
        'DisplayAlerts = False
        Alerts False
            Call WriteProjectDeadlineToFinalMilestone
            LevelingClear All:=True
            UpdateProject All:=True, UpdateDate:=Now, Action:=2
            Application.RepublishAssignments False, pjPublishScopeAll, False, True, True, ""
            fnWait (2)
            UpdateProjectToWeb EmbedProjectFile:=True
            'MailSendProjectMail MessageType:="TeamPublishAll", Subject:="Publish New and Changed Assignments", Body:="Below are the latest schedule changes. Contact your project manager if there are any problems with the changes.", ShowDialog:=False, PublishScope:=1
        Alerts True
        fnWait (2)
       'DisplayAlerts = True
        FileClose pjSave
    End Sub

    So you could build a looping construct that finds out the status date of projects and if it is below a certain threshold then call the Sub.

    It is important to also be aware that this sub will overwrite and not process the updates the resources have submitted.

    My use case is accept all updates from PWA, All those projects open themselves. Then I apply the Sub. Then I have a list of Projects that have not been modified recently. And call the Sub separately on those via the custom form, and just let it run.

    Friday, December 27, 2013 8:58 PM