Add element to Hub header

50 views Asked by At

the hub design is builded in MSN's app, like sport, new, weather.

I want to use that, too.

I study textbook and found that tutorial.

but that only teach add header to hub

<Hub Header="this header"> </Hub>

not include element

in msn app, it has search icon in header.

How to do that?

2

There are 2 answers

0
Burak Kaan Köse On BEST ANSWER

Hub class has a content presenter in itself and can present HubSection which you can find detailed MSDN page by clicking here

I don't know which MSN app you are mentioning , but if you want to search icon in your Headers you must modify HeaderTemplate to achieve that.

4
pART On
<Hub Header="Text Your Header">
    <Hub.HeaderTemplate>
         <DataTemplate>
              <!-- Put you element here -->
              <!-- Below is example -->
              <ListBox>
                   <ListBoxItem>No.1 </ListBoxItem>
                   <ListBoxItem>No.2 </ListBoxItem>
              </ListBox>
         </DataTemplate>
    </Hub.HeaderTemplate>
</Hub>