• 使用NuGet安装EntityFramework4.2


    1、下载NuGet

    有两种方式下载NuGet

    第一种:在微软的档案库下载,下载地址为:http://visualstudiogallery.msdn.microsoft.com/27077b70-9dad-4c64-adcf-c7cf6bc9970c?SRC=VSIDE

    弟二种:在vs2010的Tools中Extension Manager-》OnlineGallery 中搜索NuGet并下载安装

    2、安装NuGet

    在安装NuGet时,遇到了一个错误

    Error: The Package Manager Console requires PowerShell 2.0 runtime, which is not detected on this machine. 
    Please install the PowerShell 2.0 from http://support.microsoft.com/kb/968929 and restart Visual Studio.

    解决方案:卸载PowerShell 1.0

    卸载后,能正确的安装成功

    3、安装EntityFramework4.2

    在 Package Manager Console 中 运行Install-Package EntityFramework

    遇到错误

    Install-Package : The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel.
    At line:1 char:16
    + Install-Package <<<<  EntityFramework
        + CategoryInfo          : NotSpecified: (:) [Install-Package], WebException
        + FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PowerShell.Commands.InstallPackageCommand
     解决方案:

    修改package Source为:http://packages.nuget.org/v1/FeedService.svc/

  • 相关阅读:
    mysql 时间函数
    Excel名称管理
    Unicode中文和特殊字符的编码范围
    带有历史数据置顶的id列表查询
    汉字表示范围
    ASP.NET模拟http进行GET/POST请求
    ASP.NET AES-128-CBC加密解密(与php通讯)
    dapper.net 获取分页存储过程返回的多结果集
    微信网页版抓包登录
    js添加/移除/阻止事件
  • 原文地址:https://www.cnblogs.com/lyl6796910/p/3766705.html
Copyright © 2020-2023  润新知