TFS Custom Links in MS Project 2010


As a project manager, one of the most powerful features of Team Foundation Server 2010 is the ability to create links between work items.  While there are several different kinds of links that are built into TFS by default, you’ll often want to create custom link types to streamline your reporting as well as the interface within VSTS. 

MS Project integrates tightly with TFS and recognises two different kinds of relationships when you are importing work items from the system.

Hierarchy — This is the tree-based relationship that allows work items to roll up into each other.  In MS project, this is represented by summary tasks with all of the children under it.  By default, TFS uses System.LinkTypes.Hierarchy for this relationship.

Dependency — These are the relationships between work items that sets the order that they need to be accomplished in the plan.  This means that the ordering and resource leveling will follow this map.  By default, TFS uses System.LinkTypes.Dependency for this relationship.

If you need to remap these to your custom LinkTypes, it is a simple change to the FileMapping.XML file in the Template’s Classification Directory.  You simply need to add the following keys to the Mappings in the XML, specifying the names of the LinkTypes you’ve created.

HierarchyLinkType
<HierarchyLinkType LinkType=”MyNamespace.LinkTypes.MyHierarchyLinkType” />

DependencyLinkType
<DependencyLinkType LinkType=”MyNamespace.LinkTypes.MyDependencyLinkType” />

Note that the documentation on MSDN has incorrect syntax and will throw an exception when you try to export to MS Project.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s