19

What is the difference between "ListView" and "ListBox" in a "Windows 8" app.

Omer
  • 8,194
  • 13
  • 74
  • 92
Milan Aggarwal
  • 5,104
  • 3
  • 25
  • 54

2 Answers2

5

ListBox is NOT obsolete.

ListBox has many similarities with ListView or GridView (they share the parent class ItemsControl), but each control is oriented towards different scenarios. ListBox is best for general UI composition, particularly when the elements are always intended to be selectable, whereas ListView or GridView are best for data binding scenarios, particularly if virtualization or large data sets are involved.

Source: https://msdn.microsoft.com/library/windows/apps/br242868

Mike Keskinov
  • 11,614
  • 6
  • 59
  • 87
  • 2
    From the ListBox page at learn.microsoft.com:
    "ListBox is useful when you are upgrading a Universal Windows 8 app that uses ListBox, and need to minimize changes. For new apps in Windows 10, we recommend using the ListView control instead." [link]https://learn.microsoft.com/en-us/uwp/api/windows.ui.xaml.controls.listbox#definition
    – bluerain Jul 15 '19 at 23:38