This question is locked. New answers and comments are not allowed.
Hi,
The version of telerik I'm using is 2010.2.609.1040. I use the RadGridView control in my silverlight xaml file, and the foregound of the column header is white on design time, however, it is very strange that the foregound of it turns to Black on run time. So, I use GridViewHeaderCellStyle in GridViewDataColumn to set the foregound to white, but it still cannot work.
My code as below:
<Style x:Key="MyHeaderCellStyle" TargetType="telerik:GridViewHeaderCell">
<Setter Property="Foreground" Value="White" />
</Style>
<telerik:RadGridView x:Name="VirtualMachineListGrid" Grid.Row="1" ShowGroupPanel="False" CanUserInsertRows="False"
CanUserDeleteRows="False" AutoGenerateColumns="False"
ItemsSource="{Binding}">
<telerik:RadGridView.Columns>
<telerik:GridViewDataColumn Header="Name" HeaderTextAlignment="Center" IsAutoGenerated="False" Width="120"
IsReadOnly="True" DataMemberBinding="{Binding AliasName}" HeaderCellStyle="{StaticResource MyHeaderCellStyle}"/>
</telerik:RadGridView.Columns>
</telerik:RadGridView>
Even if I change the foregound color to others, it still shows black.
I use PRISM in my souce code framework. I'm not sure whether it is related to PRISM, since all are OK if I create a new silverlight application without using PRISM.
Can you help me?
Thanks
Chelsea
The version of telerik I'm using is 2010.2.609.1040. I use the RadGridView control in my silverlight xaml file, and the foregound of the column header is white on design time, however, it is very strange that the foregound of it turns to Black on run time. So, I use GridViewHeaderCellStyle in GridViewDataColumn to set the foregound to white, but it still cannot work.
My code as below:
<Style x:Key="MyHeaderCellStyle" TargetType="telerik:GridViewHeaderCell">
<Setter Property="Foreground" Value="White" />
</Style>
<telerik:RadGridView x:Name="VirtualMachineListGrid" Grid.Row="1" ShowGroupPanel="False" CanUserInsertRows="False"
CanUserDeleteRows="False" AutoGenerateColumns="False"
ItemsSource="{Binding}">
<telerik:RadGridView.Columns>
<telerik:GridViewDataColumn Header="Name" HeaderTextAlignment="Center" IsAutoGenerated="False" Width="120"
IsReadOnly="True" DataMemberBinding="{Binding AliasName}" HeaderCellStyle="{StaticResource MyHeaderCellStyle}"/>
</telerik:RadGridView.Columns>
</telerik:RadGridView>
Even if I change the foregound color to others, it still shows black.
I use PRISM in my souce code framework. I'm not sure whether it is related to PRISM, since all are OK if I create a new silverlight application without using PRISM.
Can you help me?
Thanks
Chelsea