Export (0) Print
Expand All
Expand Minimize

BuildAction Property (Visual Basic and C# ProjectItem Object)

Visual Studio .NET 2003

Returns or sets the build action to perform with the file. This value determines what the project system does with a project item during a build.

[Visual Basic .NET]
Public Property BuildAction() As prjBuildAction
[Visual Basic 6]
Property Get BuildAction() As prjBuildAction
Property Let BuildAction( _
   ByVal NewValue As String _
) 
[C++]
HRESULT __stdcall get_ BuildAction(
   /* [out, retval] */ prjBuildAction * retVal
);
HRESULT __stdcall put_ BuildAction(
   /* [in] */ prjBuildAction NewValue
);
[C#]
prjBuildAction BuildAction {get; set;}
[JScript .NET]
public function get BuildAction() : prjBuildAction
public function set BuildAction(
   NewValue : prjBuildAction
)

Parameters

NewValue
The new SubType value.

Return Value

String.

Remarks

A project may contain many project items, not all of which are code files. A code file would probably have this field set to the prjBuildActionCompile enumeration value, which would direct the system to compile the file. A text file containing programmer notes might have this field set to prjBuildActionContent to indicate that the system should not compile this file, but should deploy it as content.

The possible values of the BuildAction property are contained in the prjBuildAction enumeration.

See Also

Properties Property (General Extensibility) | ProjectItem Object | prjBuildAction Enumeration

Applies To: Properties Property (Visual Basic and C# ProjectItem Object)

Show:
© 2014 Microsoft