title: Debug an Error in a Custom SharePoint Web Service
body: <p>I have created a custom SharePoint web service that was deployed to, and successfully tested on, a test environment.  Unfortunately, the web service has since stopped working, and I am trying to determine what the error is.</p>
  
  <p>The web service now returns the following error in the SOAP response:</p>
  
  <pre><code>SOAP:server
  Server was unable to process request.  Object reference not set to an instance of an object.
  </code></pre>
  
  <p>There have been no changes to the deployed web service, so I am assuming that a  more recent deployment has altered the SharePoint configuration.  My web service .asmx is deployed to the _vti_bin folder, and the assembly is deployed to the GAC.  I can see the WSDL file being displayed when I browse to <a href="http://servername:port/_vti_bin/MyCustomWebService.asmx" rel="nofollow noreferrer">http://servername:port/_vti_bin/MyCustomWebService.asmx</a>.  The web methods in the assembly make use of logging (to the Windows Event log), but no logging is occurring when I try and access the web service, which suggests that the call  is not getting as far as entering the web method.   </p>
  
  <p>Given the above, can anyone offer any suggestions as to debug this issue?   </p>
  
  <p>Thanks. MagicAndi.</p>
  
  <p><strong>Update</strong><br>
  I have now realised that when I consume the web service from the endpoint <a href="http://servername:port/Site/_vti_bin/MyCustomWebService.asmx" rel="nofollow noreferrer">http://servername:port/Site/_vti_bin/MyCustomWebService.asmx</a>, it works, but when I use the endpoint <a href="http://servername:port/_vti_bin/MyCustomWebService.asmx" rel="nofollow noreferrer">http://servername:port/_vti_bin/MyCustomWebService.asmx</a>, the web service fails as described above.  I will update further when I diagnose the cause of the issue.</p>