VS error:

The “Microsoft.Build.Tasks.Xaml.PartialClassGenerationTask” task could


not be loaded from the assembly C:\Program Files (x86)\Microsoft


Visual


Studio\2019\Enterprise\MSBuild\Current\Bin\amd64\XamlBuildTask.dll.


Could not load file or assembly ‘file:///C:\Program Files


(x86)\Microsoft Visual


Studio\2019\Enterprise\MSBuild\Current\Bin\amd64\XamlBuildTask.dll’ or


one of its dependencies. The system cannot find the file specified.


Confirm that the <UsingTask> declaration is correct, that the assembly


and all its dependencies are available, and that the task contains a


public class that implements Microsoft.Build.Framework.ITask.

For the solution, modify the Visual Studio installation (using the Visual Studio Setup program) by looking for Windows Workflow Foundation on the Single Component TAB and selecting it.