Object reference not set to an instance of an object on build web site

孤者浪人 提交于 2019-12-02 00:47:02

问题


I have a web site that is just serving as a Remoting Server and has remoting configuration inside its web.config file.

<system.runtime.remoting>
    <application>
      <service>
        <activated type="abc.def.ghi"/>
      </service>
      <channels>
        <channel ref="http" machineName="localhost"/>
      </channels>
    </application>
  </system.runtime.remoting>

Besides this web.config file, it has only these files in it:

dataConfiguration.config
enterpriseLibrary.config
log.config
website.publishproj
bin folder - which has the DLLs that are served from this project via remoting

When I build the web site, I receive build error which is:

"object reference not set to an instance of an object".

How can I debug what's causing this error and how to remove it?

Please advise.


回答1:


The issue is resolved. I had a assembly reference in my web.config where there was a version mismatch between it and the assembly present inside the bin folder:

<add assembly="Oracle.DataAccess, Version=4.112.3.0, Culture=neutral, PublicKeyToken=89B483F429C47342"/>


来源:https://stackoverflow.com/questions/16280965/object-reference-not-set-to-an-instance-of-an-object-on-build-web-site

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!