Xceed DataGrid for Silverlight Documentation
CellContentTemplate Property
Example 


Gets or sets the DataTemplate used to display the content of the cells in the column.
Syntax
'Declaration
 
Public Property CellContentTemplate As DataTemplate
'Usage
 
Dim instance As Column
Dim value As DataTemplate
 
instance.CellContentTemplate = value
 
value = instance.CellContentTemplate
public DataTemplate CellContentTemplate {get; set;}

Property Value

The DataTemplate used to display the content of the cells in the column.
Example
<sldg:Column FieldName="Freight">
    <sldg:Column.CellContentTemplate>
        <DataTemplate>
            <TextBlock Text="{Binding StringFormat=c2}"
                       HorizontalAlignment="Center"/>
        </DataTemplate>
    </sldg:Column.CellContentTemplate>
</sldg:Column>
<DataTemplate>
     <StackPanel Orientation="Horizontal">
        <TextBlock Text="{Binding LastName}"/>
        <TextBlock Text=", "/>
        <TextBlock Text="{Binding FirstName}"/>
     </StackPanel>
</DataTemplate>
Requirements

Target Platforms: Windows 7, Windows Vista, Windows XP SP3, Windows Server 2008 family

See Also

Reference

Column Class
Column Members
Cell.OverrideColumnCellContentTemplate Method

Styles and Themes

Templating

Send Feedback