开发者

silverlight DataGrid style

开发者 https://www.devze.com 2022-12-26 21:42 出处:网络
my Datagrid is: <data:DataGrid x:Name=\"dgSearchResults\" Style=\"{StaticResource dgStyle}\" Grid.Row=\"1\"ColumnHeaderStyle=\"{StaticResource dgHeaderStyle}\" >

my Datagrid is:

<data:DataGrid x:Name="dgSearchResults" Style="{StaticResource dgStyle}" Grid.Row="1"  ColumnHeaderStyle="{StaticResource dgHeaderStyle}" >

I have defined styles in my App.xaml file:

<Style x:Key="dgStyle" TargetType="data:DataGrid">
        <Setter Property="Background" Value="White"/>
        <Setter Property="RowBackground" Value="#FFF6F6F6"/>
        <Setter Property="Foreground" Value="#FF3A3B3B"/>
        <Setter Property="FontFamily" Value="Verdana"/>
        <Setter Property="FontSize" Value="13.333"/>
    </Style>

EXCEPTION--> Invalid at开发者_JAVA百科tribute value data:DataGrid for property TargetType. [Line: 61 Position: 43]


Your App.xaml does not contain the following namespace alias:-

xmlns:data="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Data"
0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号