다음을 통해 공유


BuildPropertyGroup.AddNewProperty Method (String, String, Boolean)

Adds a new BuildProperty with the specified Name and Value to the BuildPropertyGroup.

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 AddNewProperty ( _
    propertyName As String, _
    propertyValue As String, _
    treatPropertyValueAsLiteral As Boolean _
) As BuildProperty
public BuildProperty AddNewProperty(
    string propertyName,
    string propertyValue,
    bool treatPropertyValueAsLiteral
)
public:
BuildProperty^ AddNewProperty(
    String^ propertyName, 
    String^ propertyValue, 
    bool treatPropertyValueAsLiteral
)
member AddNewProperty : 
        propertyName:string * 
        propertyValue:string * 
        treatPropertyValueAsLiteral:bool -> BuildProperty
public function AddNewProperty(
    propertyName : String, 
    propertyValue : String, 
    treatPropertyValueAsLiteral : boolean
) : BuildProperty

Parameters

  • treatPropertyValueAsLiteral
    Type: System.Boolean

    true to treat the propertyValue parameter as a literal value; otherwise, false.

Return Value

Type: Microsoft.Build.BuildEngine.BuildProperty
The new BuildProperty.

.NET Framework Security

See Also

Reference

BuildPropertyGroup Class

AddNewProperty Overload

Microsoft.Build.BuildEngine Namespace