title: Dynamic datagrid columns in Flex
body: <p>I have <code>&lt;mx:DataGrid&gt;</code> in my system like the following.</p>
  
  <pre><code>&lt;mx:DataGrid id="testDG"&gt;
    &lt;mx:columns&gt;
      &lt;mx:DataGridColumn headerText="name" dataField="name"&gt;
      &lt;mx:DataGridColumn headerText="measure" dataField="measure"&gt;
    &lt;/mx:columns&gt;
  &lt;/mx:DataGrid&gt;
  </code></pre>
  
  <p>It has two columns, <code>name</code> and <code>measure</code>. I want to add another number of columns and it's data in the datagrid as respect to <code>measure</code>.</p>
  
  <p>So, it looks like:</p>
  
  <pre><code>name  measure  1-Aug  2-Aug   3-Aug ...
  
  abc   ggggg    20      22      24   ...
  xyz   fffff    21      19      20   ...
  pqr   hhhhh    30      21      13   ...
  
  ...    ...     ...     ...     ...
  </code></pre>
  
  <p>I want to add <code>date</code> wise result followed by <code>measure</code> column dynamically. <br/> So, is it possible? How can I add dynamic columns after measures in Flex?</p>