Exercise 3: Working with Hierarchical Work Items in Visual Studio and Project

In this exercise, you will learn how to manage hierarchical work items from within Visual Studio and get a taste of how to take advantage of Project for more detailed project management.

  1. It is possible to work with the same iteration tasks that we did in the previous exercise from within Visual Studio. In Team Explorer, navigate to Work Items | Team Queries | Iteration 3 and double-click on the Iteration Backlog.

    Figure 1

    Iteration Backlog query for iteration 3

  2. There are a number of beneficial UI mechanisms that make working with these work items easier from within Visual Studio. Try clicking the + and buttons associated with the user story work items to see that they can collapse and expand if they contain children.
  3. Drag and drop a task from one user story to a different user story. Notice that the changes are displayed in bold.

    Figure 2

    Changes are displayed in bold

  4. Select a child task with a single left-click and then use the green Indent arrow to change the hierarchy level.

    Figure 3

    Indent arrow location

  5. To add additional nested work items that may use any of the supported link types, right-click on an existing task (it does not matter which one) and select New Linked Work Item from the context menu.

    Figure 4

    New Linked Work Item…

  6. Expand the Link Type drop down to see all of the supported link types.

    Figure 5

    Supported link types

  7. We are not going to save these changes for the purposes of this lab, so select the Cancel button to return to the Iteration 3 work items.
  8. Select the Refresh button to return to the original list of work items, selecting No when prompted to save the modified work items.

    Figure 6

    Refresh button location

  9. Microsoft Project can also be used to work with TFS work items in order to create a more detailed project plan. Select the Open in Microsoft Office drop down and click on the Open Query in Microsoft Project option.

    Figure 7

    Open Query in Microsoft Project

  10. After Project loads, re-adjust the screen real estate so that you can clearly see the Titles of the work items. Note that this data is used to create a Gantt chart in the right-hand pane.

    Figure 8

    Initial view in Microsoft Project

  11. TFS 2010 also introduces support for successor/predecessor relationship between work items. Select the Predecessors column for work item with ID=33 and enter 2,4 into that cell. This designates that work items with ID=32 and 34 must be completed first. The numbers 2 and 4 that you entered correspond to the row numbers within Project.

    Figure 9

    Editing work item successor/predecessor relationship

  12. Add some more successor/predecessor relationships by making work item ID=36 have a predecessor of work item ID=35 by entering 6 into the Predecessors column. Also make work item ID=38 have predecessors for work items with IDs 37 and 39.

    Figure 10

    Final view of Predecessors column

Although it is outside the scope of this lab to do so, you can use Microsoft Project to create much more detailed project plans by defining additional start and end dates for each work item.
  1. Save changes back to TFS by selecting a cell from the work item table and then select the Publish button.
  2. Return to Visual Studio and double-click on the work item task with ID=33 titled “Implement web front-end for viewing all open orders”.
  3. Select the All Links tab to verify that work items 32 and 34 are listed as predecessors of this work item task.

    Figure 11

    All Links tab for work item showing predecessors

Next Step

Exercise 4: Introduction to MSF Agile Process Sample Documents