Is there any in-built grouping for ListBoxes or another UI control? I would like to have a list but have some form of grouping or sections applied to the list. As shown below:
heading one
list item one
list item two
heading two
list item one
list item two
list item three
list item four
Is there anything available for such purpose without building something from scratch? I don't wish to mix a match multiple ListBoxes, rather I would prefer a solution where this was handled at the data binding level.
LongListSelector comes to mind.
Using LongListSelector without LINQ - Andy Pennell's Blog
WP7 LongListSelector in depth | Part1: Visual structure and API | WindowsPhoneGeek
WP7 LongListSelector in depth | Part2: Data binding scenarios | WindowsPhoneGeek
Alternatively, you could look into applying either of these grouping implementations to the phone's listbox.
Confessions of a ListBox groupie [Using IValueConverter to create a grouped list of items simply and flexibly] - Delay's Blog
How to group items in a list by their first letter in Silverlight? - Stack Overflow
You want to look at the "Long List Selector" in the Silverlight for Windows Phone Toolkit
Its a control that looks+behaves just like the grouping behavior in contacts/etc on the phone.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With