ImportGroup Element

 

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

Contains a collection of Import elements that are grouped under an optional condition. For more information, see Import Element (MSBuild).

<Project>
<ImportGroup>

<ImportGroup Condition="'String A' == 'String B'">  
    <Import ... />  
    <Import ... />  
</ImportGroup>  

The following sections describe attributes, child elements, and parent elements.

Attributes

AttributeDescription
ConditionOptional attribute.

The condition to be evaluated. For more information, see Conditions.

Child Elements

ElementDescription
ImportImports the contents of one project file into another project file.

Parent Elements

ElementDescription
ProjectRequired root element of an MSBuild project file.

The following code example shows the ImportGroup element.

<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">  
    <ImportGroup>  
        <Import Project="$(Targets1.targets) />  
        <Import Project="$(Targets2.targets) />  
    </ImportGroup>  
...  
</Project>  

Project File Schema Reference
Items

Show: