title: Databinding the DataGrid column header in code
body: <p>How do I databind a <a href="http://www.codeplex.com/wpf/Release/ProjectReleases.aspx" rel="nofollow noreferrer">WPF Toolkit DataGrid</a> column header value <em>in code</em> (not XAML)? </p>
  
  <pre><code>DataGridColumn fooColumn =  new DataGridTextColumn 
  {
    Header = "Foo",
    Binding = new Binding {Path = new PropertyPath("BindingPath"), 
                           Mode = BindingMode.OneWay}
  };
  </code></pre>
  
  <p>This databinds the content of the cells of the column. But how do I databind the header text ("Foo") itself (to, say, a string property on a viewmodel)?</p>