I am getting one error when I am trying to populate binding source. The exception is as follows;
System.IndexOutOfRangeException: Index 0 does not have a value.
at System.Windows.Forms.CurrencyManager.get_Item(Int32 index)
at System.Windows.Forms.DataGridView.DataGridViewDataConnection.GetError(Int32 rowIndex)
I am using generic list to fill binding source. The code looks like,
foreach (listItem)
{
BindingSource.Add(listItem);
}
I tried resetting the datasource property, but still the same issue.
Please help me to resolve this issue.