Click here to Skip to main content
15,891,423 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi All,
How do I use a group style with ItemsPanelTemplate,
But I want the gorup to be stack horizntal and the wrappanel like this:

*************
*a:1 2 3 b:1*
*2 3 c:1 2 3*
*d:1 2 3 e:1*
*2 3 *
*************

I tried this:

XML
<GroupStyle.Panel>
    <ItemsPanelTemplate>
        <WrapPanel Orientation="Horizontal" />
    </ItemsPanelTemplate>
</GroupStyle.Panel>


and with / without

XML
<ListView.ItemsPanel>
   <ItemsPanelTemplate>
       <StackPanel Orientation="Horizontal"/>
   </ItemsPanelTemplate>           
</ListView.ItemsPanel> 


but it gave me
**************
*a:1 2 3 *
*b:1 2 3 *
*c:1 2 3 *
*d:1 2 3 *
*e:1 2 3 *
**************

I even tried the opposite way the group style panel to be stack and the list view to be wrap panel.
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900