Common MSBuild Properties

Top  Previous  Next

Listed here are common properties used in the MSBuild project system to extract important path and configuration information:

$(TargetPath)

The full path of the resulting binary.

Example: c:\my project\debug\mydll.dll

$(TargetDir)

The path of the resulting binary.

Example: c:\my project\debug\

$(SolutionDir)

The path where the solution (.sln) file exists.

Example: c:\my project\

$(MSBuildProjectDirectory)

The path where the project file exists.

Example: c:\my project\

$(Configuration)

The configuration being built.

Example: Debug