title: System.NullReferenceException On WCF call
body: <p>I'm having quite a difficulty trying to trace this bug. At first I thought it was linq SQL data that's causing NRE because every time I look at the tracer log, it gives me the .cs line 37 which is pointed to my sql (stored proc) call. The reason I suspect this, the result of this sproc is null (not NULL) but there's no row return for all the fields. What I did was to put data on it, and now comes the frustration; I still get the same error. Maybe it's worth mentioning that when I use the WCF as reference(not servicereferences) a DLL straight to bin then it works perfect, only when I try to use the client (mywebservice.client) one.</p>
  
  <p>Any ideas where I should be looking? It is on app.config? Also, I'm using a console app to access the WCF.</p>
  
  <p>This is my code:</p>
  
  <pre><code>public static List&lt;usp_GetPaymentsResult&gt; GetScheduledPayment(DateTime DateRun, int Fee)
      {
          try
          {
  
              PaymentDataContext DBContext = new PaymentDataContext();
              return DBContext.usp_GetPayments(DateRun, Fee).ToList(); //line 37
          }
          catch (SqlException ex)
          {
              throw ex;
  
          }
          catch (Exception ex)
          {
              throw ex;
          }
      }
  </code></pre>