Welcome to MSDN Blogs Sign in | Join | Help

Editing MSBuild project files in Visual Studio

Being able to edit your Visual Studio generated projects is one of the fundamental goals of MSBuild.  Being able to edit your project file to customize and extend is not something that just happened to work :) MSBuild and Visual Studio 2005 were designed right from the start to enable you to do this.  If you ask me, this is the "essence of MSBuild"

So let's say you are working on your project, and have your project loaded in the IDE - What's the easiest way for you to be able to quickly drop into the MSBuild project file (either .csproj or .vbproj) so that you can edit the project to customize your build?

Pretty simple - if you are using one of the builds past the June CTP, you can do this in two steps.

1. Right click on your project in solution explorer and select Unload Project

2. Right click on the project (tagged as unavailable in solution explorer) and click "Edit yourproj.csproj"

It's that simple.  No more notepad.  No more File->Open->blah->blah->blah.  Besides, you get full inellisense based on the MSBuild schema!  Wait - there's something better.  We will not touch any of the customizations you make to your projects.  Customizations will work inside the IDE as well as from the command line - but we will not mess with your changes!

[Author: Faisal Mohamood]

Published Thursday, September 29, 2005 2:50 AM by msbuild
Filed under: ,

Comment Notification

If you would like to receive an email when updates are made to this post, please register here

Subscribe to this post's comments using RSS

Comments

Friday, December 02, 2005 9:49 AM by Anders Ljusberg

# re: Editing MSBuild project files in Visual Studio

Is there an easy way to check out the project file from TFS without checking every single file in the project? That would be rather handy..
Tuesday, January 17, 2006 5:40 AM by Serge Baccou

# re: Editing MSBuild project files in Visual Studio

Thanks a lot. This tip is very useful. I have blogged about this...
Thursday, April 06, 2006 11:23 AM by Scott Munro

# Edit project files from the comfort of your own IDE.

Anyone who has edited Visual Studio project xml using Notepad (the no man's land of intellisense) will...
Monday, August 28, 2006 8:47 AM by test

# Sandcastle Visual Studio Project

Final update Sorry, I'm not able to figure out what's wrong with this, and since Frank has a better solution
Monday, August 28, 2006 8:48 AM by test

# Opening a .csproj file in the Visual Studio 2005 IDE

Been pulling my hair to find an way to open up a .csproj file in the Visual Studio 2005 IDE. After lots
Saturday, September 16, 2006 11:33 AM by Smöråkning

# Opening a .csproj file in the Visual Studio 2005 IDE

Been pulling my hair to find an way to open up a .csproj file in the Visual Studio 2005 IDE. After lots
Saturday, September 16, 2006 11:39 AM by Smöråkning

# Sandcastle Visual Studio Project

Final update Sorry, I'm not able to figure out what's wrong with this, and since Frank has a better solution

Leave a Comment

(required) 
required 
(required) 
 
Page view tracker