Freigeben über


SolutionBuild.BuildProject Method

Builds the specified project and its dependencies in the context of the specified solution configuration.

Namespace:  EnvDTE
Assembly:  EnvDTE (in EnvDTE.dll)

Syntax

'Declaration
Sub BuildProject ( _
    SolutionConfiguration As String, _
    ProjectUniqueName As String, _
    WaitForBuildToFinish As Boolean _
)
void BuildProject(
    string SolutionConfiguration,
    string ProjectUniqueName,
    bool WaitForBuildToFinish
)
void BuildProject(
    String^ SolutionConfiguration, 
    String^ ProjectUniqueName, 
    bool WaitForBuildToFinish
)
abstract BuildProject : 
        SolutionConfiguration:string * 
        ProjectUniqueName:string * 
        WaitForBuildToFinish:bool -> unit
function BuildProject(
    SolutionConfiguration : String, 
    ProjectUniqueName : String, 
    WaitForBuildToFinish : boolean
)

Parameters

  • SolutionConfiguration
    Type: System.String

    Required. The name of the new solution configuration that provides the context in which to build the project.

  • ProjectUniqueName
    Type: System.String

    Required. The project to build.

  • WaitForBuildToFinish
    Type: System.Boolean

    Optional. Determines whether to wait for the build to complete. If true, then waits, otherwise, no.

Remarks

BuildProject returns immediately. To determine when a solution build operation is complete, you must check the OnBuildDone event.

BuildProject does not affect the user interface (UI) in terms of changing the active solution configuration or selected project. To build the project relative to the active solution configuration, use DTE.SolutionBuild.ActiveConfiguration.Name.

BuildProject does affect the UI based on the DTE.SuppressUI flag in that the Status Bar flickers and the Output window and Task List are always updated.

The specified project and all its dependencies are built as long as the dependencies are checked to be built in the specified solution configuration.

.NET Framework Security

See Also

Reference

SolutionBuild Interface

EnvDTE Namespace