4

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.

teenup
  • 7,459
  • 13
  • 63
  • 122
  • 3
    Ok, what made you think the problem lies in your web.config and not in the website itself you're trying to build? – walther Apr 29 '13 at 14:25
  • I thought it is serving the objects from the assemblies which are present in the bin folder and they are configured to be served in the `web.config` as `` elements. Besides these two things - the bin and web.config, I can't guess what can be the cause. – teenup Apr 29 '13 at 14:28
  • Build errors usually point to a specific line of code...You really don't have to guess, you just need to read the message (`WHOLE MESSAGE`) and find out which line is the problematic one. We can't debug this for you by looking at your web.config. – walther Apr 29 '13 at 14:56

2 Answers2

5

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"/>
teenup
  • 7,459
  • 13
  • 63
  • 122
0

This error appears when Target framework is not selected. enter image description here

  • Your answer could be improved with additional supporting information. Please [edit] to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers [in the help center](/help/how-to-answer). – Community Apr 23 '22 at 13:44