0
votes

I have a solution containing .NET Framework project - WPF application, frontend - and multiple .NET Standard projects - backend. I need to build the .NET Framework project, but to do it, I must build the .NET Standard projects, because the .NET Framework project references the .NET Standard projects.

Visual Studio Build and MSBuild throw errors like "'System' namespace doesn't exist" in the .NET Standard projects.

Net Core build fails to find some assemblies in certain Nuget packages, namely Prism and DevExpress.

How should I build .NET Framework WPF app that is referencing .NET Standard in Azure DevOps?

1
can you share your yaml?Newton Sheikh
Sorry, cannot reproduce this case. Could you build this solution successfully on local machine? Could you provide a sample solution to reproduce above error?Levi Lu-MSFT
Just set up a C# WPF App project (.NET 4.7.2) referencing a .NET Standard 2.0 project (library). The library references Newtonsoft.Json for example. How do you build this? Finally, I changed the reference, the WPF is referencing a DLL, not the project. Is there a more elegant way to build the projects together with a single build step? (Now it is two steps: 1 - .NET Standard -> DLLs, 2 - .NET Framework with .NET Standard DLLs)LordGneisenau
I just used the Visual Studio Build task to build the solution. If you see above error, you can try setting the restoreNugetPackages: true of Visual Studio Build task.Levi Lu-MSFT

1 Answers

0
votes

Thanks Levi Lu for his reply. It is the solution. Reposting it here:

" I just used the Visual Studio Build task to build the solution. If you see above error, you can try setting the restoreNugetPackages: true of Visual Studio Build task. "