This project has moved. For the latest updates, please go here.

CellContentTemplate and bindind not working

May 10, 2014 at 2:15 AM
Edited May 10, 2014 at 8:05 AM
hi, i have some questions :

1) is the FieldName property required for the Column ?

2) what the difference between Column and UnboundColumn

3) the databinding seems to have no effect inside CellContentTemplate
  <xcdg:Column Width="90" FieldName="ID_ADHERANT"  >

                                <TextBlock Width="90" Height="25" Text="{Binding ID_ADHERANT}"/>
i have checked that i don't have databinding errore in VS debugger

i need this templated column to some stuff and controls(progressbars/buttons... etc) and not only a single value
thanks and good day
May 21, 2014 at 12:35 PM

You can find the doc for the complete Xceed WPF DataGrid here :

1) Yes the FieldName is required to identify the column you want to define in the DataGrid. It uniquely identifies the column in a grid's column collection.

2) A column is a regular colum that is displayed in the PropertyGrid. It defines information on how the cells they contain are displayed and their content edited.
An unbound column is a column that can be used to display non-data related information such as a label or controls that allow some sort of action to be carried out (e.g., a button to open a window in which the current item can be edited). Unlike data bound columns, unbound columns cannot be grouped or sorted, nor can their values be filtered.

3) Try removing the "ID_ADHERANT" in the Binding.
Here's an example :
<xcdg:Column Width="90"
                     <TextBlock Width="90"
                                Text="{Binding}" />