title: ASP.NET MVC 3 - WebGrid - data source
body: <p>I am new to ASP.NET MVC 3. I am trying to create a basic WebGrid to try and learn how this works. Currently, I have the following code:</p>
  
  <pre><code>@{
      ViewBag.Title = "Home Page";
  }
  
  &lt;h2&gt;@ViewBag.Message&lt;/h2&gt;
  &lt;p&gt;
  @{
      var grid = new WebGrid();
  }
  @grid.GetHtml()
  &lt;/p&gt;
  </code></pre>
  
  <p>When I run this code, I receive an error that says: "A data source must be bound before this operation can be performed.". My question is, how do I bind this WebGrid to some client-side JSON. I don't have a back-end database. I'm just trying to learn about the WebGrid without having to wireup a database.</p>
  
  <p>thanks!</p>