Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Adds a new BuildItem with the specified Name and Include property values to the BuildItemGroup, allowing you to specify whether the Include property value is treated as a literal.
MSBuild is now included in Visual Studio instead of the .NET Framework. You can use MSBuild 12.0 side-by-side with versions previously deployed with the .NET Framework.For more information, see What's New in MSBuild 12.0.
Namespace:  Microsoft.Build.BuildEngine
Assembly:  Microsoft.Build.Engine (in Microsoft.Build.Engine.dll)
Syntax
'Declaration
Public Function AddNewItem ( _
    itemName As String, _
    itemInclude As String, _
    treatItemIncludeAsLiteral As Boolean _
) As BuildItem
public BuildItem AddNewItem(
    string itemName,
    string itemInclude,
    bool treatItemIncludeAsLiteral
)
public:
BuildItem^ AddNewItem(
    String^ itemName, 
    String^ itemInclude, 
    bool treatItemIncludeAsLiteral
)
member AddNewItem : 
        itemName:string * 
        itemInclude:string * 
        treatItemIncludeAsLiteral:bool -> BuildItem
public function AddNewItem(
    itemName : String, 
    itemInclude : String, 
    treatItemIncludeAsLiteral : boolean
) : BuildItem
Parameters
- itemName 
 Type: System.String
- itemInclude 
 Type: System.String
- treatItemIncludeAsLiteral 
 Type: System.Boolean- true to treat the itemInclude parameter as a literal value; otherwise, false. 
Return Value
Type: Microsoft.Build.BuildEngine.BuildItem
The new BuildItem.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see dd66cd4c-b087-415f-9c3e-94e3a1835f74.