Hi, i have a wpf datagrid,
heres my datagrid
<dg:DataGrid x:Name="dataGrid" AutoGenerateColumns="false"
ColumnHeaderStyle="{StaticResource columnHeaderStyle}"
AlternationCount="2" RowBackground="Beige"
RowStyle="{StaticResource rowStyle}"
AlternatingRowBackground="LightBlue"
HeadersVisibility="All"
HorizontalGridLinesBrush="#DDDDDD"
VerticalGridLinesBrush="#DDDDDD" Grid.ColumnSpan="2" Margin="0,0,0,26" IsReadOnly="True" ColumnHeaderHeight="30">
<dg:DataGrid.Columns>
<dg:DataGridTextColumn Header=" Task Id" Binding="{Binding Path=TaskId}" Width="60" />
<dg:DataGridTextColumn Header="Order Description" Binding="{Binding Path=OrderDescription}" Width="120"/>
<dg:DataGridTextColumn Header="Final Client Name" Binding="{Binding Path=ClientName}" Width="110"/>
<dg:DataGridTextColumn Header="Order Date" Binding="{Binding Path=OrderDate}" Width="80"/>
<dg:DataGridTextColumn Header="Task Description" Binding="{Binding Path=TaskDescription}" Width="130"/>
<dg:DataGridTextColumn Header="Group Name Short" Binding="{Binding Path=GroupNameShort}" Width="116"/>
<dg:DataGridTemplateColumn MinWidth="100" Header=" Actions">
<dg:DataGridTemplateColumn.CellTemplate>
<DataTemplate>
<Button Click="DetailButton_Click">Close</Button>
</DataTemplate>
</dg:DataGridTemplateColumn.CellTemplate>
</dg:DataGridTemplateColumn>
</dg:DataGrid.Columns>
</dg:DataGrid>
In aspx to change text we use onrowdatabound for example, here in wpf how can i change the field Order Description and Order Date. I have two funtions to change the text, that are convertDatetimeToDate(string datetime) e htmltotext(string text).