title: Datagrid binding in WPF
body: <p>I know this has been asked already but I have done almost everything what is suggested by developers.</p>
  <pre><code>&lt;DataGrid x:Name=&quot;Imported&quot; VerticalAlignment=&quot;Top&quot;
            DataContext=&quot;{Binding Source=list}&quot;
            AutoGenerateColumns=&quot;False&quot; CanUserResizeColumns=&quot;True&quot;&gt;
      &lt;DataGrid.Columns&gt;                
          &lt;DataGridTextColumn Header=&quot;ID&quot; Binding=&quot;{Binding Path=ID}&quot;/&gt;
          &lt;DataGridTextColumn Header=&quot;Date&quot; Binding=&quot;{Binding Path=Date}&quot;/&gt;
      &lt;/DataGrid.Columns&gt;
  &lt;/DataGrid&gt;
  </code></pre>
  <p>I am trying to show this in modal dialog box and populating the license list in the constructor of the modal dialog box.
  But still nothing is getting populated inside the <code>DataGrid</code>.</p>
  <p>Constructor code:</p>
  <pre><code>public diagboxclass()
  {
      List&lt;object&gt; list = new List&lt;object&gt;();
      list = GetObjectList();
  }
  public class object
  {
      string id;
      DateTime date;
      public string ID
      {
          get { return id; }
          set { id = value; }
      }
      public DateTime Date
      {
          get { return date; }
          set { date = value; }
      }
  }
  </code></pre>
  <p>Do you guys think something to do with the object list?</p>