by brad
26. January 2010 14:41
We’ve recently been looking at importing Microsoft Project tasks into TFS so that the developers can see their tasks inside visual studio. However the first snag was that TFS work items aren’t able to support more than one resource being assigned to them, a problem when your Project Manager has allocated more than one developer to do the same thing!
Also some of the tasks in the project plan are assigned to the client, E.g. ‘Sign Off Wireframes’ and by default TFS will only allow you to assign work items to valid users than exist in your companies Active Directory.
I got round the multiple resources issue by creating TFS security groups, e.g _BradMatt, but then i needed to update the Task definition in TFS so it would only show relevant items, and allow entries that aren’t users in AD.
First i needed to export the current ‘Task’ definition in XML, this is done from the command line using:
witexport /f c:\task.xml /t [tfservername] /p [teamprojectname] /n task
Then changed the following XML from:
<FIELD name="Assigned To" refname="System.AssignedTo" type="String" reportable="dimension">
<VALIDUSER />
</FIELD>
to:
<FIELD name="Assigned To" refname="System.AssignedTo" type="String" reportable="dimension">
<ALLOWEDVALUES expanditems="true">
<LISTITEM value="[Project]\Contributors" />
<LISTITEM value="Client" />
</ALLOWEDVALUES>
</FIELD>
Then re-imported it using the following command:
witimport /f c:\task.xml /t [tfsservername] /p [teamprojectname] /n Task
Then make sure to refresh the Project in Visual Studio’s Team Explorer.