title: An unhandled exception of type 'System.InvalidOperationException' occurred in mscorlib.dll
body: <pre><code>    private void findManagerForSelectedDate(String dateSelected)
      {
          dateSelected = dateTimePicker1.Value.ToShortDateString();
  
          List&lt;String&gt; managerNames = new List&lt;String&gt;();
          foreach(var item in managers)
          {
              foreach (var subitem in item)
              {
                  CalendarModel c = subitem;
                  Console.WriteLine(c.date);
                  c.name = new CultureInfo("en-US", false).TextInfo.ToTitleCase(c.name);
                  if (userSelection.Count &gt; 0)
                  {
                      foreach (var addedUser in userSelection)
                      // Crashing here with An unhandled exception of type 'System.InvalidOperationException' occurred in mscorlib.dll
                      {
                          if (!addedUser.Contains(c.name))
                          {
                              userSelection.Add(c.name);
                          }
                      }
                  } else
                  {
                      userSelection.Add(c.name);
                  }
  </code></pre>
  
  <p>It was able to iterate thru my list 3 times then on the 4th time, it crashed.</p>
  
  <p>The Exception details says <strong>{"Collection was modified; enumeration operation may not execute."}</strong></p>