更新 xamarin 表单后出现以下异常。
Exception thrown: 'System.TypeLoadException' in System.Private.CoreLib.ni.dll An exception of type 'System.TypeLoadException' occurred in System.Private.CoreLib.ni.dll but was not handled in user code Could not load type 'Xamarin.Forms.Xaml.XamlResourceIdAttribute' from assembly 'Xamarin.Forms.Core, Version=2.0.0.0, Culture=neutral, PublicKeyToken=null'.
我在从 2.5.0.121934 安装 xamarin forms 3.1.0.912540 后遇到了这个问题。
截图如下:
最佳答案
该问题已在 xamarin 论坛和 the solution 中报告是为了
- 清理解决方案中的所有项目
- 关闭 Visual Studio
- 从所有项目(共享和设备(Android、iOS、UWP)特定)中删除所有
bin
和obj
文件夹 - 重启 IDE,构建解决方案。
关于xamarin.forms - Xamarin 表单 UWP : Exception thrown: 'System.TypeLoadException' in System. Private.CoreLib.ni.dll,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/53044549/