A while back I came a problem:
I needed to build for a client an activity that runs on an unknown number of projects and builds them with DevEnv 2005/2008/2010.
I needed to create an editor that allows the user to select projects to be built in DevEnv and additional properties for each project such as “DevEnv version” and “Configuration to build”.
The problem was that I had very little time to do this.
This is where my good friend Baruch Frei came into the picture; He informed me that when I build a simple dumb object such as:
and add a List<T> of that object to the builds “Process Template” as an argument like this:
What we will see in the “Process” tab of the “Edit Build Definition” window is the Microsoft “out of the box” editor of the List<T> object in TFS build definition.
This editor will hand us the functionality of adding and removing objects of type T to and from the list as well as to edit each of the public properties of the object.
On the left side you see the object in the list, displayed by their ToString() method, and on the right you see a properties grid of the selected object on the left.
What is also nice is that if you have in your object properties such as Boolean or Enum the properties grid will inflict those restrictions in the form of a drop down.
Easy and fast.