How to set Resources for DataGridTemplateColumn

Jun 9, 2009 at 9:34 AM

I implement a Customize Control of DataGridTemplateColumn and let it derive from DataGridTemplateColumn, but how to set its Resources, since I have one defined ResourceDictonary.

Dose anyone know the answer?Thanks very much! Dan

Jun 9, 2009 at 9:44 PM

Hi Dan,

You should be able to set the Resources on the DataTemplate which you put inside the CellTemplate of your DataGridTemplateColumn, like so:

                            <DataTemplate Resources="...">

Is that what you were looking for?


Jun 16, 2009 at 11:48 AM
Edited Jun 16, 2009 at 11:49 AM


If i want sorting facility on this "DataGridTemplateColumn" then How can i do it Because i tried it but Sorting is not Working on this......

Jun 16, 2009 at 10:16 PM

Hi Yagnesh2879,

This article will show you how to setup your Custom sorting for a DatgridTemplateColumn.