I have a grid like this:
<telerik:RadGridView x:Name="DataG"ItemsSource="{Binding CamposUsu}"SelectedItem="{Binding Selected}"CanUserReorderColumns="True"CanUserResizeColumns="True"CanUserSortColumns="False"SelectionUnity="FullRow"IsReadyOnly="True"AutoGenerateColumns="False"Loaded="DataG_Loaded" />
In the .cs file the method DataG_Loaded:
private void DataG_Loaded(object sender, RoutedEventesArgs e)
{
DataTemplate labelTemplate = new DataTemplate();
FrameworkElementFactory label = new FrameworkElementFactory(typeof(Label));
label.SetValue(Label.ContentProperty, "Unlimited");
labelTemplate.VisualTree = label;
labelTemplate.Seal();this.DataG.Columns[7].CellTemplate = labelTemplate;
//this column 7 is a column called "Vl." with double values
}
Well, when I comment the method DataG_Loaded, my grid is fulfilled correctly with the objects I created on my viewmodel. When I uncomment the method, the column "Vl." that had values like "93.5", "108.9"... is all fulfilled with the value "Unlimited".
This was already expected. I want only the cells that the value is > 100.0 to turn to the string "Unlimited".
Is there any way of doing this?