zoukankan      html  css  js  c++  java
  • 遇到的错误记录

    1、在asp.net Boilerplate项目中,Abp.0.12.0.2,.net framework4.5.2。下载后添加了webApi的helpPage功能,调试出现错误。

    dubug : at AreasHelpPageViewsHelpDisplayTemplatesHelpPageApiModel.cshtml Samples error:
    D: project MyWebMyWeb.WebAreasHelpPageViewsHelpDisplayTemplatesSamples.cshtml (6): error CS0012: Type "System.Collections.Generic.Dictionary'2 <T0,T1>" defined in the Assembly that is not referenced. You must add the assemblies "System.Collections, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" reference.

    解决方法:在 Web.config, node <system.web> <assemblies>, adding
    <add assembly="System.Collections, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />

    解决:http://www.lyalin.com/2014/04/25/the-type-system-object-is-defined-in-an-assembly-that-is-not-reference-mvc-pcl-issue/ 

    2、还是1的项目,debug时候正常,但发布到iis时候出现错误:

    编译错误

    说明: 在编译向该请求提供服务所需资源的过程中出现错误。请检查下列特定错误详细信息并适当地修改源代码。 

    编译器错误消息: CS0012: 类型“System.Object”在未被引用的程序集中定义。必须添加对程序集“System.Runtime, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a”的引用。

    解决方法:在web.config中,node <system.web> <assemblies>, adding

    <add assembly="System.Runtime, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />

    效果:

    <system.web>
        <!--<trust level="Full" />-->
        <globalization culture="auto" uiCulture="auto"/>
        <compilation debug="true" targetFramework="4.5.2">
          <assemblies>
            <add assembly="System.Runtime, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
            <add assembly="System.Collections, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
          </assemblies>
        </compilation>
        
        <httpRuntime/>
        <customErrors mode="Off"/>
        <pages controlRenderingCompatibilityVersion="4.0"/>
      </system.web>
    

      参考网址:http://www.lyalin.com/2014/04/25/the-type-system-object-is-defined-in-an-assembly-that-is-not-reference-mvc-pcl-issue/

  • 相关阅读:
    状态线程
    C++编译 C # 调用方法
    图像算法集合
    openmp 和 thread 性能实测
    RGB转YUV 各种库的性能比较
    ipp 实现图像空间的转换
    Eigen 学习笔记
    线性代数笔记
    凸优化 笔记
    Windows系统服务器中安装Redis服务
  • 原文地址:https://www.cnblogs.com/heifengwll/p/6213378.html
Copyright © 2011-2022 走看看