Failed to load Xamarin Forms project with .NET Standard 2.0 Lib in Rider

前端 未结 2 1927
说谎
说谎 2021-01-02 08:48

TL;DR; Are Xamarin Forms projects with .NET Standard library 2.0 supported in Rider?

I created a small Xamarin project in Visual Studio 2017.3 (Wind

相关标签:
2条回答
  • 2021-01-02 09:02

    The problem is caused by Rider selecting the wrong MSBuild file to use. The .NET Core SDK installs a version of MSBuild that isn't configured to use the Xamarin SDK.

    In Rider goto File > Settings > Build, Execution Deployment > Toolset and Build > Use MSBuild version. Select the MSBuild.dll that does not reside in the .NET Core SDK path:

    On Windows that will be under Microsoft Visual Studio on MacOS that appears to be under the Mono.framework.

    It is important that you fully restart Rider after making this change. After making the change, Rider will try to do a rebuild and fail. Making it seem like your change didn't work. But it appears that the setting doesn't take effect until Rider is fully restarted.

    0 讨论(0)
  • 2021-01-02 09:10

    Go to File | Settings | Build, Execution, Deployment | Toolset and Build and change MsBuild from mono. I guess you have all Xamarin targets installed in that msbuild.

    0 讨论(0)
提交回复
热议问题