Hen*_*gen 7 c# entity-framework xamarin xamarin.forms
实体框架7目前作为Beta版本提供,本文指出在Xamarin项目中使用Entity Framework 7是可能的(将会是?).
但是,当我尝试使用NuGet安装它时:
Install-Package EntityFramework.SQLite –Pre
Run Code Online (Sandbox Code Playgroud)
它会失败:
Install-Package : Could not install package 'EntityFramework.Sqlite 7.0.0-beta6'. You are trying to install this package into a
project that targets '.NETPortable,Version=v4.5,Profile=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.
At line:1 char:1
+ Install-Package EntityFramework.SQLite –Pre
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Install-Package], Exception
+ FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
Run Code Online (Sandbox Code Playgroud)
有没有办法在Xamarin项目中使用Entity Framework,还是我必须坚持使用sqlite-net?
编辑:正如@Daniel Luberda建议的那样,我只是尝试将实体框架安装到从Xamarin.Forms共享项目模板创建的项目中,但是这失败并出现以下错误:
Install-Package : Could not install package 'System.Runtime 4.0.20-beta-23109'. You are trying to install this package into a project that targets 'MonoAndroid,Version=v5.1', 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.
At line:1 char:1
+ Install-Package EntityFramework.SQLite –Pre
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Install-Package], Exception
+ FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
Run Code Online (Sandbox Code Playgroud)
Windows Phone项目和iOS项目也是如此.
| 归档时间: |
|
| 查看次数: |
7746 次 |
| 最近记录: |