title: Problem when using Entity Framework in ASP.NET MVC
body: <p>I use Entities Framework to implement my data accsee layer in ASP.NET MVC. I got a problem in View.</p>
  
  <p>When my code in the VIEW something like:</p>
  
   
  
  <p>I got an error in run time:</p>
  
  <p>Object reference not set to an instance of an object. </p>
  
  <p>Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. </p>
  
  <p>Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.</p>
  
  <p>Source Error: </p>
  
  <p>Line 14:     <p>
  Line 15:     &lt;%= Model.FirstName %>
  Line 16:     </p>
  Line 17: </p>
  
  <p>This is generated from strong-typed view template.
  I ensured that I added model referrence to web.config
  I didn't encounter this error when I was using LINQ to SQL</p>
  
  <p>Any help?</p>