What is the difference between WPF's ListBox and ListView? I can not find any significant difference in their properties. Is there different typical use?
.net – The difference between ListBox and ListView
netwpfwpf-controlswpf-listview
Related Topic
- .net – What are differences between AssemblyVersion, AssemblyFileVersion and AssemblyInformationalVersion
- C# – Deep cloning objects
- C# – What are the correct version numbers for C#
- C# – Difference between InvariantCulture and Ordinal string comparison
- .net – In WPF, what are the differences between the x:Name and Name attributes
- C# – In C#, what is the difference between public, private, protected, and having no access modifier
- .net – Difference between decimal, float and double in .NET
- .net – the difference between .NET Core and .NET Standard Class Library project types
Best Answer
A
ListView
is basically like aListBox
(and inherits from it), but it also has aView
property. This property allows you to specify a predefined way of displaying the items. The only predefined view in the BCL (Base Class Library) isGridView
, but you can easily create your own.Another difference is the default selection mode: it's
Single
for aListBox
, butExtended
for aListView