Dynamic DataGrid Creation in Flex 3

Hi All

Can anyone please suggest me a way to create a data grid dynamically in Flex 3.(I actually was want to create it thru Action Script.)
The data would come from the XML and the rows of the grid are also not going to be fixed. It will be dependent on the number of nodes in the XML.
The data grid will have 3 columns 1 containing a text field, and the rest 2 will contain small icons, all created dynamically.
It would be gr8 if some code related to that can be provided.

Thanks for any help that can be provided.
Vicky