6

In the devexpress grid below how do I bind to the current row data in the column template and use a converter object.

<dxg:GridControl ItemsSource="{Binding Data}" FontSize="16">
    <dxg:GridControl.View>
        <dxg:TableView AutoWidth="True" AllowEditing="False" AllowColumnMoving="False" NavigationStyle="None" ShowIndicator="False" AllowColumnFiltering="False" ShowGroupPanel="False" AllowPerPixelScrolling="True" AllowBestFit="True"/>
    </dxg:GridControl.View>
    <dxg:GridControl.Columns>
           
        <dxg:GridColumn Header="Field1" FieldName="Field1">
            <dxg:GridColumn.DisplayTemplate>
                <ControlTemplate>
    <!-- how do i bind to current row data-->
                </ControlTemplate>
            </dxg:GridColumn.DisplayTemplate>
        </dxg:GridColumn>
    </dxg:GridControl.Columns>
</dxg:GridControl>
wonea
  • 4,783
  • 17
  • 86
  • 139
TrustyCoder
  • 4,749
  • 10
  • 66
  • 119

1 Answers1

8
<ControlTemplate>
    <TextBlock Text="{Binding Path=RowData.Row.FieldName}">
    </TextBlock>
</ControlTemplate>
wonea
  • 4,783
  • 17
  • 86
  • 139
TrustyCoder
  • 4,749
  • 10
  • 66
  • 119