none
WBS codes in a master project RRS feed

  • Question

  • Hi All

    I'm using MSproject Standard 2010

    I've created a 'master' project and inserted a number of subprojects. The WBS field allocates a number to each new subproject but doesn't carry this through to the task level WBS which reflects the WBS of the individual subproject. Basically, I just want to add the subproject level WBS to the front of the task level WBS.

    Hope this makes sense !?! All advice welcomed.

    Thanks for your help

    PS - have MS sorted the problem with project bloat yet ???

    Friday, May 3, 2013 10:04 AM

Answers

  • Greetings from the valleys,

    If you run the following code on your master project, it will update the WBS field as you describe.

    Sub SetSubPjWBSNos()
    Dim pj As Project
    Dim spj As Subproject
    Dim t As task
    Set pj = activeProject
    For Each spj In pj.Subprojects
        For Each t In spj.SourceProject.Tasks
        
            If t Is Nothing Then GoTo NextTask
            If t.ExternalTask Then GoTo NextTask
            
        
            t.WBS = spj.InsertedProjectSummary.WBS & "." & t.outlineNumber
        
    NextTask:
        Next t
    Next spj
    End Sub

    Thanks,
    Andrew

    PS. I'm using Project2010, and we still suffer from bloat.

    • Marked as answer by Swansea_Jack Friday, May 3, 2013 1:33 PM
    Friday, May 3, 2013 11:46 AM

All replies

  • Greetings from the valleys,

    If you run the following code on your master project, it will update the WBS field as you describe.

    Sub SetSubPjWBSNos()
    Dim pj As Project
    Dim spj As Subproject
    Dim t As task
    Set pj = activeProject
    For Each spj In pj.Subprojects
        For Each t In spj.SourceProject.Tasks
        
            If t Is Nothing Then GoTo NextTask
            If t.ExternalTask Then GoTo NextTask
            
        
            t.WBS = spj.InsertedProjectSummary.WBS & "." & t.outlineNumber
        
    NextTask:
        Next t
    Next spj
    End Sub

    Thanks,
    Andrew

    PS. I'm using Project2010, and we still suffer from bloat.

    • Marked as answer by Swansea_Jack Friday, May 3, 2013 1:33 PM
    Friday, May 3, 2013 11:46 AM
  • Hi Andrew

    diolch yn fawr - works a treat !!

    iechyd da !

    Swansea Jack

    Friday, May 3, 2013 1:35 PM