title: C# program stopped execution while converting LINQ Date to string
body: <p>I am working on C# with entity framework 6.
  when my program control reaches following line of code.</p>
  
  <pre><code>Date= j.Date.Value.ToShortDateString()
  </code></pre>
  
  <p>it stops its execution..</p>
  
  <p>Following is Entity Frame work Join Query Code</p>
  
  <pre><code>            SCIMSEntities db = new SCIMSEntities();
          var list = from i in db.tblVendors
                  join j in db.tblVendorPaymentBillsHistories on i.Id equals j.Vendor_Id
                  select new clsAddBillToVendor
                  {
                      id= j.Id,
                      CompanyName= i.CompanyName,
                      BillNo= j.BillNo,
                      Details= j.Details,
                      BilllAmount= j.BillAmount.Value,
                      Date= j.Date.Value.ToShortDateString(),
                      TotalAmount= j.TotalAmount.Value
                  };
               return list; 
  </code></pre>