Xamarin 错误:未安装框架:.NETPortable,版本 = v4.5 [英] Xamarin Error: Framework not installed: .NETPortable, Version=v4.5

查看:26
本文介绍了Xamarin 错误:未安装框架:.NETPortable,版本 = v4.5的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我成功安装了 Xamarin 并创建了一个新项目.根本没有代码,我在引用下收到以下错误,并得到 Xamarin.Forms 丢失的错误.我尝试搜索,但在修复建议的工作中没有看到相同的错误.谢谢.

I installed Xamarin successfully and create a new project. With no code at all I'm getting the following error under the references and get errors that Xamarin.Forms is missing. I tried searching and I'm not seeing this same error where the fixes suggested work. Thank you.

错误:

Framework not installed: .NETPortable, Version=v4.5

系统设置:

Windows 7(内部版本 7601:Service Pack 1)

Windows 7 (Build 7601: Service Pack 1)

Xamarin Studio 5.1.4(内部版本 0)

Xamarin Studio 5.1.4 (Build 0)

Visual Studio 11.0.50727.1 RTMREL 终极版

Visual Studio 11.0.50727.1 RTMREL Ultimate

.NET 框架版本 4.5.50709

.NET Framework Version 4.5.50709

尝试从 VisualStudio 启动项目时出现以下错误:

Tried to start project from VisualStudio got the following error:

所以我以管理员身份开始尝试其他方法,输出如下:

Adding Xamarin.Forms...
Installing 'Xamarin.Forms 1.0.6186'.
Added file 'Xamarin.Forms.Build.Tasks.dll' to folder 'Xamarin.Forms.1.0.6186\build\portable-win+net45+wp80+MonoAndroid10+MonoTouch10'.
Added file 'Xamarin.Forms.targets' to folder 'Xamarin.Forms.1.0.6186\build\portable-win+net45+wp80+MonoAndroid10+MonoTouch10'.
Added file 'Xamarin.Forms.Core.dll' to folder 'Xamarin.Forms.1.0.6186\lib\MonoAndroid10'.
Added file 'Xamarin.Forms.Core.xml' to folder 'Xamarin.Forms.1.0.6186\lib\MonoAndroid10'.
Added file 'Xamarin.Forms.Platform.Android.dll' to folder 'Xamarin.Forms.1.0.6186\lib\MonoAndroid10'.
Added file 'Xamarin.Forms.Xaml.dll' to folder 'Xamarin.Forms.1.0.6186\lib\MonoAndroid10'.
Added file 'Xamarin.Forms.Xaml.xml' to folder 'Xamarin.Forms.1.0.6186\lib\MonoAndroid10'.
Added file 'Xamarin.Forms.Core.dll' to folder 'Xamarin.Forms.1.0.6186\lib\MonoTouch10'.
Added file 'Xamarin.Forms.Core.xml' to folder 'Xamarin.Forms.1.0.6186\lib\MonoTouch10'.
Added file 'Xamarin.Forms.Platform.iOS.dll' to folder 'Xamarin.Forms.1.0.6186\lib\MonoTouch10'.
Added file 'Xamarin.Forms.Xaml.dll' to folder 'Xamarin.Forms.1.0.6186\lib\MonoTouch10'.
Added file 'Xamarin.Forms.Xaml.xml' to folder 'Xamarin.Forms.1.0.6186\lib\MonoTouch10'.
Added file 'Xamarin.Forms.Core.dll' to folder 'Xamarin.Forms.1.0.6186\lib\portable-win+net45+wp80+MonoAndroid10+MonoTouch10'.
Added file 'Xamarin.Forms.Core.xml' to folder 'Xamarin.Forms.1.0.6186\lib\portable-win+net45+wp80+MonoAndroid10+MonoTouch10'.
Added file 'Xamarin.Forms.Xaml.dll' to folder 'Xamarin.Forms.1.0.6186\lib\portable-win+net45+wp80+MonoAndroid10+MonoTouch10'.
Added file 'Xamarin.Forms.Xaml.xml' to folder 'Xamarin.Forms.1.0.6186\lib\portable-win+net45+wp80+MonoAndroid10+MonoTouch10'.
Added file 'Xamarin.Forms.Core.dll' to folder 'Xamarin.Forms.1.0.6186\lib\WP80'.
Added file 'Xamarin.Forms.Core.xml' to folder 'Xamarin.Forms.1.0.6186\lib\WP80'.
Added file 'Xamarin.Forms.Platform.WP8.dll' to folder 'Xamarin.Forms.1.0.6186\lib\WP80'.
Added file 'Xamarin.Forms.Xaml.dll' to folder 'Xamarin.Forms.1.0.6186\lib\WP80'.
Added file 'Xamarin.Forms.Xaml.xml' to folder 'Xamarin.Forms.1.0.6186\lib\WP80'.
Added file 'Xamarin.Forms.1.0.6186.nupkg' to folder 'Xamarin.Forms.1.0.6186'.
Successfully installed 'Xamarin.Forms 1.0.6186'.
Adding 'Xamarin.Forms 1.0.6186' to Test.
Could not install package 'Xamarin.Forms 1.0.6186'. You are trying to install this package into a project that targets 'portable-Profile78', but the package does not contain any assembly references or content files that are compatible with that framework. For more information, contact the package author.

推荐答案

如果您没有安装 Visual Studio,以下步骤对我有用:

If you don't have Visual Studio installed the following steps worked for me:

  1. 下载 便携式工具 2 扩展并使用 /buildmachine 开关安装它:PortableLibraryTools.exe/buildmachine

  1. Download the Portable Tools 2 extension and install it using the /buildmachine switch: PortableLibraryTools.exe /buildmachine

下载可移植类库 v4.6 并安装它.

复制C的内容(目录v4.0v4.5v4.6):\Program Files (x86)\Microsoft .NET Portable Library Reference Assemblies 4.6C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable(覆盖任何现有文件).[如果您想安全起见,请备份原始文件!]

Copy the contents (directories v4.0, v4.5 and v4.6) of C:\Program Files (x86)\Microsoft .NET Portable Library Reference Assemblies 4.6 into C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETPortable (overwriting any existing files). [Backup the original files if you want to be on the safe side!]

这篇关于Xamarin 错误:未安装框架:.NETPortable,版本 = v4.5的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆