Hack the Build: Programmatically Converting Older VS .NET Projects to MSBuild

Jomo Fisher–There are plenty of reasons you might want to programmatically convert projects from VS .NET 2003 format to MSBuild format. Maybe you have a bunch of old .csproj files and you’d like to convert them in batch. Maybe you’d like to keep your projects in VS7 format and convert them to MSBuild format on…


MSBuild Sample Code Demonstrating How to Convert Older Projects to VS8 Format

/*Use of included script samples are subject to the terms specified at http://www.microsoft.com/info/cpyright.htmWritten by Jomo Fisher*/ using System;using System.Text;using Microsoft.Build.Conversion; class ConvertProject{ static void Main(string[] args) {  ProjectFileConverter c = new ProjectFileConverter();  c.OldProjectFile = args[0];  c.NewProjectFile = args[1];   c.Convert(); }}