error message is as below when the commented line is there:
Operation is not valid while ItemsSource is in use. Access and modify elements with ItemsControl.ItemsSource instead.
My source code is as attached.
Appreciate any useful help.
================================
I have found the answer. Replace the commented line with
lucky_listBox.ItemsSource =
null;
Vikrant MorePosted Jun 12, 2012, 2:01 AM
lucky_listBox.Items.Clear();