Edit

Share via


MSB4036 diagnostic code

This article describes the MSB4036 error code.

Message text

MSB4036: The 'value' task was not found. Check the following: 1.) The name of the task in the project file is the same as the name of the task class. 2.) The task class is 'public' and implements the Microsoft.Build.Framework.ITask interface. 3.) The task is correctly declared with <UsingTask> in the project file, or in the *.tasks files located in the 'value' directory.

Remarks

This error occurs when MSBuild is trying to load a task, but it couldn't find it, or what it found could not be loaded as a task. The task name is given in the error message. Using the name of the task, try to determine whether the task is one of yours, or a system task. Check the task name as referenced in the UsingTask element, and make sure it's correct. See Configure targets and tasks

If the task is one you're developing, make sure the task class is public as suggested, and implements Microsoft.Build.Framework.ITask. Also, make sure the task and its transitive dependencies are loadable. For .NET Core, you can check the .NET assembly load logging. See How to use and debug assembly unloadability in .NET. For a .NET Framework task, you can do this by viewing Fusion log.

If the task isn't your own custom task, there might be a corruption problem with the installation of MSBuild, .NET SDK, or Visual Studio. Reinstalling these tools might solve the problem.

Applies to

All versions of MSBuild