Skip to content

Commit 86f3227

Browse files
authored
Merge pull request #13829 from GitHubber17/415544-h
410544 - MSBuild error article updates
2 parents 4687cc9 + ce545b2 commit 86f3227

File tree

11 files changed

+238
-83
lines changed

11 files changed

+238
-83
lines changed

docs/msbuild/errors/msb6011.md

Lines changed: 22 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
2-
title: "MSB6011"
3-
description: "Invalid parameters passed to the 'task-name' task."
4-
ms.date: "07/07/2021"
2+
title: MSB6011 diagnostic code
3+
description: Learn about the possible causes of the MSB6011 build error and get troubleshooting tips.
4+
ms.date: 04/16/2025
55
ms.topic: "error-reference"
66
f1_keywords:
77
- MSB6011
@@ -16,8 +16,24 @@ ms.author: ghogen
1616
manager: mijacobs
1717
ms.subservice: msbuild
1818
---
19-
# MSB6011: Invalid parameters passed to the 'task-name' task
19+
# MSB6011
2020

21-
This error occurs when a task indicates that the parameters passed to it are not valid. Normally, a task generates a customized error message in that case, by specifying such in the implementation of the `ValidateParameters` method. If the task doesn't override that method, the base ToolTask version of that method is used, which generates this error.
21+
This article describes the MSB6011 error code.
2222

23-
If the task is provided by a vendor, consider contacting the vendor and asking them to implement the `ValidateParameters` method on the task. If this is your own custom task, consider implementing that method to provide a detailed message that indicates what parameter was invalid and why.
23+
## Message text
24+
25+
`MSB6011: Invalid parameters passed to the 'task-name' task.`
26+
27+
## Description
28+
29+
This error occurs when a task indicates that the parameters passed to it are invalid. In most cases, a task generates a customized error message by specifying such in the implementation of the `ValidateParameters` method. If the task doesn't override the `ValidateParameters` method, the base ToolTask version of that method is used, which generates the error.
30+
31+
## Resolution
32+
33+
If the task is provided by a vendor, you might contact the vendor and ask them to implement the `ValidateParameters` method on the task.
34+
35+
If the implementation uses your own custom task, consider implementing the `ValidateParameters` method to provide a detailed message that identifies the invalid parameter and reason.
36+
37+
## Applies to
38+
39+
All versions of MSBuild

docs/msbuild/errors/msb8003.md

Lines changed: 28 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
2-
title: "MSBuild warning MSB8003"
3-
description: "MSBuild warning MSB8003 occurs when a build property isn't defined. Some build tools may not be found."
4-
ms.date: 10/29/2021
2+
title: MSB8003 diagnostic code
3+
description: Learn about the possible causes of the MSB8003 build error and get troubleshooting tips.
4+
ms.date: 04/16/2025
55
ms.topic: "error-reference"
66
f1_keywords:
77
- MSB8003
@@ -12,12 +12,32 @@ ms.author: ghogen
1212
manager: mijacobs
1313
ms.subservice: msbuild
1414
---
15-
# MSBuild warning MSB8003
15+
# MSB8003
1616

17-
> MSB8003: The *property-name* property is not defined. Some build tools may not be found.
17+
This article describes the MSB8003 error code.
1818

19-
To resolve this issue, define a supported value for the specified property.
19+
## Message text
2020

21-
This error can occur when the `VCToolsInstallDir` property hasn't been set. This error may occur if you haven't installed a C++ workload in the Visual Studio Installer. You can use the Visual Studio Installer to install workloads and optional components. For more information, see [Modify Visual Studio](../../install/modify-visual-studio.md). Choose one of the C++ workloads to install the C/C++ toolset. Use the **Individual components** tab in the installer to choose specific platforms, libraries, and SDKs.
21+
`MSB8003: The *property-name* property is not defined. Some build tools may not be found.`
2222

23-
This error can also occur when the `WindowsSDKDir` property hasn't been set in your project. Since Visual Studio 2015, the Windows SDK hosts the headers and libraries for the C runtime library. We recommend you install and use the latest available Windows SDK in the Visual Studio Installer, and set the **Windows SDK Version** property in your project property pages to match.
23+
## Description
24+
25+
This error occurs when a build property isn't defined.
26+
27+
Common causes for this error include:
28+
29+
- The `VCToolsInstallDir` property isn't set.
30+
- The `WindowsSDKDir` property isn't set in your project.
31+
- A C++ workload isn't installed with the Visual Studio Installer.
32+
33+
## Resolution
34+
35+
Define a supported value for the specified property, such as the `VCToolsInstallDir` or `WindowsSDKDir` property.
36+
37+
Use the Visual Studio Installer to install workloads and optional components. For more information, see [Modify Visual Studio](../../install/modify-visual-studio.md). Choose one of the C++ workloads and install the C/C++ toolset. Use the **Individual components** tab in the installer to choose specific platforms, libraries, and SDKs.
38+
39+
Since Visual Studio 2015, the Windows SDK hosts the headers and libraries for the C runtime library. We recommend you install and use the latest available Windows SDK in the Visual Studio Installer, and set the **Windows SDK Version** property in your project property pages to match.
40+
41+
## Applies to
42+
43+
All versions of MSBuild

docs/msbuild/errors/msb8004.md

Lines changed: 19 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
2-
title: "MSBuild warning MSB8004"
3-
description: "MSBuild warning MSB8004 occurs when an intermediate or output directory doesn't end with a trailing slash."
4-
ms.date: 10/29/2021
2+
title: MSB8004 diagnostic code
3+
description: Learn about the possible causes of the MSB8004 build error and get troubleshooting tips.
4+
ms.date: 04/16/2025
55
ms.topic: "error-reference"
66
f1_keywords:
77
- MSB8004
@@ -12,10 +12,22 @@ ms.author: ghogen
1212
manager: mijacobs
1313
ms.subservice: msbuild
1414
---
15-
# MSBuild warning MSB8004
15+
# MSB8004
1616

17-
> MSB8004: *property* Directory does not end with a trailing slash. This build instance will add the slash as it is required to allow proper evaluation of the *property* Directory.
17+
This article describes the MSB8004 error code.
1818

19-
This error can occur when your configuration doesn't include the trailing slash on an Intermediate or Output directory path.
19+
## Message text
2020

21-
To resolve this issue, add a trailing slash to the specified path in your configuration. You can set the **Output Directory** and **Intermediate Directory** properties for these paths in your project properties. For more information, see [General Property Page (Project)](/cpp/build/reference/general-property-page-project).
21+
`MSB8004: *property* Directory does not end with a trailing slash. This build instance will add the slash as it is required to allow proper evaluation of the *property* Directory.`
22+
23+
## Description
24+
25+
This error occurs when an intermediate or output directory doesn't end with a trailing forward slash.
26+
27+
## Resolution
28+
29+
Add a trailing forward slash (`\`) to the specified path in your configuration. You can set the **Output Directory** and **Intermediate Directory** properties for these paths in your project properties. For more information, see [General property page (project)](/cpp/build/reference/general-property-page-project).
30+
31+
## Applies to
32+
33+
All versions of MSBuild

docs/msbuild/errors/msb8005.md

Lines changed: 21 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
2-
title: "MSBuild warning MSB8005"
3-
description: "MSBuild warning MSB8005 occurs when a specified NMake build property in a makefile project doesn't exist."
4-
ms.date: 10/29/2021
2+
title: MSB8005 diagnostic code
3+
description: Learn about the possible causes of the MSB8005 build error and get troubleshooting tips.
4+
ms.date: 04/16/2025
55
ms.topic: "error-reference"
66
f1_keywords:
77
- MSB8005
@@ -12,10 +12,24 @@ ms.author: ghogen
1212
manager: mijacobs
1313
ms.subservice: msbuild
1414
---
15-
# MSBuild warning MSB8005
15+
# MSB8005
1616

17-
> MSB8005: The property '*property-name*' doesn't exist. Skipping...
17+
This article describes the MSB8005 error code.
1818

19-
This error can occur when using a makefile to build a project, and you haven't set the project properties **Build Command Line**, **Clean Command Line**, or **Rebuild All Command Line**.
19+
## Message text
2020

21-
To resolve this issue, add the specified build command lines to your project properties. For more information, see [NMake Property Page](/cpp/build/reference/nmake-property-page).
21+
`MSB8005: The property '*property-name*' doesn't exist. Skipping...`
22+
23+
## Description
24+
25+
This error occurs when a specified NMake build property in a makefile project doesn't exist.
26+
27+
The problem can occur when you use a makefile to build a project, and you don't set the project properties **Build Command Line**, **Clean Command Line**, or **Rebuild All Command Line**.
28+
29+
## Resolution
30+
31+
Add the specified build command lines to your project properties. For more information, see [NMake property page](/cpp/build/reference/nmake-property-page).
32+
33+
## Applies to
34+
35+
All versions of MSBuild

docs/msbuild/errors/msb8006.md

Lines changed: 23 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
2-
title: "MSBuild error MSB8006"
3-
description: "MSBuild error MSB8006 occurs when the platform for your project is invalid."
4-
ms.date: 05/27/2021
2+
title: MSB8006 diagnostic code
3+
description: Learn about the possible causes of the MSB8006 build error and get troubleshooting tips.
4+
ms.date: 04/16/2025
55
ms.topic: "error-reference"
66
f1_keywords:
77
- MSB8006
@@ -12,16 +12,30 @@ ms.author: ghogen
1212
manager: mijacobs
1313
ms.subservice: msbuild
1414
---
15-
# MSBuild error MSB8006
15+
# MSB8006
1616

17-
> The Platform for project '*project-name.vcxproj*' is invalid. Platform='*platform-name*'. This error may also appear if some other project is trying to follow a project-to-project reference to this project, this project has been unloaded or is not included in the solution, and the referencing project does not build using the same or an equivalent Platform.
17+
This article describes the MSB8006 error code.
18+
19+
## Message text
20+
21+
`MSB8006: The Platform for project '*project-name.vcxproj*' is invalid. Platform='*platform-name*'. This error may also appear if some other project is trying to follow a project-to-project reference to this project, this project has been unloaded or is not included in the solution, and the referencing project does not build using the same or an equivalent Platform.`
22+
23+
## Description
24+
25+
This error occurs when the platform for your project is invalid.
1826

1927
A *Platform* is a build target architecture that uses a matching set of C++ build tools and libraries, or *toolset*. Visual Studio supplies specific platform toolsets to build for Win32 (x86), x64, ARM, and ARM64 Windows targets. It also supports optional platform toolsets to build for Linux, Android, and iOS targets.
2028

21-
There are several ways to resolve this issue:
29+
This error can occur when your project specifies a platform, but it's not the one installed with Visual Studio, or Visual Studio can't find it.
30+
31+
## Resolution
32+
33+
Use the Visual Studio Installer to install optional platforms and toolsets. For more information, see [Modify Visual Studio](../../install/modify-visual-studio.md). Use the **Individual components** tab in the installer to choose specific platforms, libraries, and SDKs.
34+
35+
Most projects don't need to specify a custom platform, but it's possible to create one. For more information, see [Visual Studio C++ Project system extensibility and toolset integration](../../extensibility/visual-cpp-project-extensibility.md). After you create the custom *`.props`* and *`.targets`* files for your platform, you can select it in the IDE in the **Property Pages** dialog for your project.
2236

23-
- This error can occur when your project has specified a platform, but it's not one that Visual Studio has installed. You can use the Visual Studio Installer to install optional platforms and toolsets. For more information, see [Modify Visual Studio](../../install/modify-visual-studio.md). Use the **Individual components** tab in the installer to choose specific platforms, libraries, and SDKs.
37+
Make sure your project is loaded when its built by a referencing project. Verify your project is built for the same platform as the referencing project.
2438

25-
- You've specified a custom platform, but Visual Studio can't find it. Most projects don't need to specify a custom platform, but it's possible to create one. For more information, see [Visual Studio C++ Project system extensibility and toolset integration](../../extensibility/visual-cpp-project-extensibility.md). Once you've created the custom *`.props`* and *`.targets`* files for your platform, you can select it in the IDE in the Property Pages dialog for your project.
39+
## Applies to
2640

27-
- Make sure that the project is loaded when built by a referencing project. Verify that it's built for the same platform as the referencing project.
41+
All versions of MSBuild

docs/msbuild/errors/msb8007.md

Lines changed: 20 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
2-
title: "MSBuild error MSB8007"
3-
description: "MSBuild error MSB8007 occurs when the target platform build property doesn't exist or isn't valid."
4-
ms.date: 10/29/2021
2+
title: MSB8007 diagnostic code
3+
description: Learn about the possible causes of the MSB8007 build error and get troubleshooting tips.
4+
ms.date: 04/16/2025
55
ms.topic: "error-reference"
66
f1_keywords:
77
- MSB8007
@@ -12,8 +12,22 @@ ms.author: ghogen
1212
manager: mijacobs
1313
ms.subservice: msbuild
1414
---
15-
# MSBuild error MSB8007
15+
# MSB8007
1616

17-
> MSB8007: The Platform for project '*project-name*' is invalid. Platform='*platform-name*'. You may be seeing this message because you are trying to build a project without a solution file, and have specified a non-default Platform that doesn't exist for this project.
17+
This article describes the MSB8007 error code.
1818

19-
To resolve this issue, change the **Target Platform** property for your project to a valid value. For more information, see [General Property Page (Project)](/cpp/build/reference/general-property-page-project).
19+
## Message text
20+
21+
`MSB8007: The Platform for project '*project-name*' is invalid. Platform='*platform-name*'. You may be seeing this message because you are trying to build a project without a solution file, and have specified a non-default Platform that doesn't exist for this project.`
22+
23+
## Description
24+
25+
This error occurs when the target platform build property doesn't exist or isn't valid.
26+
27+
## Resolution
28+
29+
Change the **Target Platform** property for your project to a valid value. For more information, see [General property page (project)](/cpp/build/reference/general-property-page-project).
30+
31+
## Applies to
32+
33+
All versions of MSBuild

docs/msbuild/errors/msb8010.md

Lines changed: 20 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
2-
title: "MSBuild error MSB8010"
3-
description: "MSBuild error MSB8010 occurs when the v90 platform toolset from Visual Studio 2008 isn't installed."
4-
ms.date: 10/29/2021
2+
title: MSB8010 diagnostic code
3+
description: Learn about the possible causes of the MSB8010 build error and get troubleshooting tips.
4+
ms.date: 04/16/2025
55
ms.topic: "error-reference"
66
f1_keywords:
77
- MSB8010
@@ -12,8 +12,22 @@ ms.author: ghogen
1212
manager: mijacobs
1313
ms.subservice: msbuild
1414
---
15-
# MSBuild error MSB8010
15+
# MSB8010
1616

17-
> MSB8010: Specified platform toolset (v90) requires Visual Studio 2008. Please make sure that Visual Studio 2008 is installed on the machine.
17+
This article describes the MSB8010 error code.
1818

19-
To resolve this issue, install Visual Studio 2008 to make the v90 platform toolset available. For more information, see [Visual Studio 2008](https://www.microsoft.com/download/details.aspx?id=7873) in the Microsoft Download Center.
19+
## Message text
20+
21+
`MSB8010: Specified platform toolset (v90) requires Visual Studio 2008. Please make sure that Visual Studio 2008 is installed on the machine.`
22+
23+
## Description
24+
25+
This error occurs when the v90 platform toolset from Visual Studio 2008 isn't installed.
26+
27+
## Resolution
28+
29+
Install Visual Studio 2008 to make the v90 platform toolset available. For more information, see [Visual Studio 2008](https://www.microsoft.com/download/details.aspx?id=7873) in the Microsoft Download Center.
30+
31+
## Applies to
32+
33+
All versions of MSBuild

docs/msbuild/errors/msb8011.md

Lines changed: 27 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
2-
title: "MSBuild error MSB8011"
3-
description: "MSBuild error MSB8011 occurs when a component registration operation fails during the build."
4-
ms.date: 10/29/2021
2+
title: MSB8011 diagnostic code
3+
description: Learn about the possible causes of the MSB8011 build error and get troubleshooting tips.
4+
ms.date: 04/16/2025
55
ms.topic: "error-reference"
66
f1_keywords:
77
- MSB8011
@@ -12,16 +12,33 @@ ms.author: ghogen
1212
manager: mijacobs
1313
ms.subservice: msbuild
1414
---
15-
# MSBuild error MSB8011
15+
# MSB8011
1616

17-
> MSB8011: Failed to register output. Please try enabling Per-user Redirection or register the component from a command prompt with elevated permissions.
17+
This article describes the MSB8011 error code.
1818

19-
This error occurs when an attempt to register a component fails. A registration failure can occur for several reasons.
19+
## Message text
2020

21-
- Different permissions may be required for per-user or global registration. The IDE, developer command prompt, or *`regsvr32.exe`* process may need to run with elevated permissions (Run as Administrator).
21+
`MSB8011: Failed to register output. Please try enabling Per-user Redirection or register the component from a command prompt with elevated permissions.`
2222

23-
- Component registration may fail because required DLL dependencies couldn't be found. You may need to place dependencies in the same directory as the component to register.
23+
## Description
2424

25-
- Component registration may fail because required DLL dependencies don't match the target architecture of the component. Make sure to use dependencies built for the same architecture as your component.
25+
This error occurs when an attempt to register a component fails during the build.
2626

27-
- Component registration may fail if your component requires but doesn't define a `DllInstall` entry point.
27+
A registration failure can occur for several reasons:
28+
29+
- Different permissions might be required for per-user or global registration, including elevated permissions.
30+
- Required DLL dependencies can't be found.
31+
- Required DLL dependencies don't match the target architecture of the component.
32+
- Required `DllInstall` entry point isn't defined.
33+
34+
## Resolution
35+
36+
Try running the IDE, developer command prompt, or the *`regsvr32.exe`* process with elevated permissions (Run as Administrator).
37+
38+
Make sure to use dependencies built for the same architecture as your component. Place dependencies in the same directory as the component to enable registration.
39+
40+
If your component requires a`DllInstall` entry point, make sure the entry point is defined.
41+
42+
## Applies to
43+
44+
All versions of MSBuild

0 commit comments

Comments
 (0)