I have the following loop:
List<Reminders> reminds = new List<Reminders>();
//...
foreach (Reminders remind in reminds)
{
//....
reminds.Insert(id, new Reminders() { Title = remind.Title, Content = remind.Content, Checked = true });
}
However, an error occurs in the foreach
loop.
foreach (Reminders remind in reminds)
If I remove the reminds.Insert
statement, the error no longer occurs. I'm trying to update some entires inside of the foreach
loop. What's causing the error?