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

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.



Solution 1:[1]

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

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Pramod Kumar