title: Listbox deselect top item
body: <p>I have a listbox and I want to deselect the first selected item in the list when the loop is run because it should process a list item after item. Currently I'm using this:</p>
  
  <pre><code>var list = new object[listBoxTracks.SelectedItems.Count];
  for (int i = 1; i &lt; listBoxTracks.SelectedItems.Count; i++)
      list[i - 1] = listBoxTracks.SelectedItems[i];
  
  listBoxTracks.SelectedItems.Clear();
  foreach (var track in list)
      listBoxTracks.SelectedItems.Add(track);
  </code></pre>
  
  <p>I think/know that this is probably very bad but I have no idea what other possibilities there are. I tried stuff with selectedIndex += 1 etc but that seems to crash it. If this has been answered before I'm sorry but I haven't found anything in my research :/</p>