开发者

wp7 pivotcontrol set header null

For a PivotControl, I am using code like this to set the Title and Header Property to null, but the pivotcontrol still displays a string in the Header with the name of the object that is being bound for that PivotItem. I want to basically hide everything in the Header of the PivotItem. How should I do this?

<controls:Pivot 
    x:Name="PivotControl"
    TitleTemplate="{x:Null}"
    HeaderTemplate="{x:Null}"
    ItemsSource="{Binding TestEntries}" 
    ItemTemplate="{StaticResource TestEntryItemTemplate}"
    SelectionChanged="PivotControl_Selectio开发者_开发技巧nChanged" LoadedPivotItem="PivotControl_LoadedPivotItem">
</controls:Pivot>


Did something like this:

    <DataTemplate x:Key="TestEntryHeaderTemplate">
        <TextBlock Text="" Height="1"></TextBlock>
    </DataTemplate>

and for PivotControl

    <controls:Pivot 
        x:Name="PivotControl"
        Title="{StaticResource AppName}"
        HeaderTemplate="{StaticResource TestEntryHeaderTemplate}" 
        ItemsSource="{Binding TestEntries}" 
        ItemTemplate="{StaticResource TestItemTemplate}"
        SelectionChanged="PivotControl_SelectionChanged" LoadedPivotItem="PivotControl_LoadedPivotItem">
    </controls:Pivot>
0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜