MSBuild Project File Schema Reference

 

For the latest documentation on Visual Studio 2017, see Visual Studio 2017 Documentation.

Provides a table of all the MSBuild XML Schema elements with their available attributes and child elements.

MSBuild uses project files to instruct the build engine what to build and how to build it. MSBuild project files are XML files that adhere to the MSBuild XML schema. This section documents the XML schema definition (.xsd) file for MSBuild.

The following table lists all of the MSBuild XML schema elements along with their child elements and attributes.

ElementChild ElementsAttributes
Choose Element (MSBuild)Otherwise

When
--
Import Element (MSBuild)--Condition

Project
ImportGroup ElementImportCondition
Item Element (MSBuild)ItemMetaDataCondition

Exclude

Include

Remove
ItemDefinitionGroup Element (MSBuild)ItemCondition
ItemGroup Element (MSBuild)ItemCondition
ItemMetadata Element (MSBuild)ItemCondition
OnError Element (MSBuild)--Condition

ExecuteTargets
Otherwise Element (MSBuild)Choose

ItemGroup

PropertyGroup
--
Output Element (MSBuild)--Condition

ItemName

PropertyName

TaskParameter
Parameter Element--Output

ParameterType

Required
ParameterGroup ElementParameter--
Project Element (MSBuild)Choose

Import

ItemGroup

ProjectExtensions

PropertyGroup

Target

UsingTask
DefaultTargets

InitialTargets

ToolsVersion

TreatAsLocalProperty

xmlns
ProjectExtensions Element (MSBuild)----
Property Element (MSBuild)--Condition
PropertyGroup Element (MSBuild)PropertyCondition
Target Element (MSBuild)OnError

 Task
AfterTargets

BeforeTargets

Condition

DependsOnTargets

Inputs

KeepDuplicateOutputs

Name

Outputs

Returns
Task Element (MSBuild)OutputCondition

ContinueOnError

 Parameter
TaskBody Element (MSBuild)DataEvaluate
UsingTask Element (MSBuild)ParameterGroup

TaskBody
AssemblyFile

AssemblyName

Condition

TaskFactory

TaskName
When Element (MSBuild)Choose

ItemGroup

PropertyGroup
Condition

Task Reference
Conditions
MSBuild Reference
MSBuild

Show: