Hi I am using WPF and adding records one by one to the listview.ItemsSource. My data will appear when all the data is included, but I want to show the data as it is added o
// Create a collection of Type System.Collections.ObjectModel.ObservableCollection
// Here T can be anything but for this example, we use System.String
ObservableCollection names = new ObservableCollection();
// Assign this collection to ItemsSource property of ListView
ListView1.ItemsSource = names;
// Start adding items to the collection
// They automatically get added to ListView without a need to write any extra code
names.Add("Name 1");
names.Add("Name 2");
names.Add("Name 3");
names.Add("Name 4");
names.Add("Name 5");
// No need to call ListView1.Items.Refresh() when you use ObservableCollection.