DataGrid cell template for the Autogenerated columns true.

Dec 19, 2009 at 7:35 PM

I am using WPF datagrid from WPFtoolkit to show data from a datatable binded to itemsource of the Datagrid. Since the columns of the table are changing i am using autogenerated columns = "True". I want to show the data in the cell in different colors based on the value in the Cell. For e.g. If the value is positive it should be Green, if value is Negative value should be Red.
How can i create and set the Cell templates for the Autogenerated Columns and then set the foreground color of the cell accordingly.

Note : I using PRISM v2