I want to change the color of a ListViewItem
in a ListView
by it´s index.
But when I do this, I get a NullReferenceException
:
Brush brush = new SolidColorBrush(Windows.UI.Colors.Green);
(baustellenListView.Items.ElementAt(i) as ListViewItem).Foreground = brush;
baustellenListView
is the name of the ListView
.
Thank you for help!