the objects added to a list of bindingsource must have all of the same type -System.InvalidOperationException
i am using a datagrid
this.bindingSourcelotesprog.DataSource = _context.Lots.Where
the datagrid has values from diferent tables with lamda i can get all this values
now i want to add a new row to the grid
and i am using Lots_Grelha as the type
should i must Lots to add a new item?
bindingSourcelotesprog.Add(new Lots_Grelha
{
article_reference="",
article_name =cmbArtigo.Text,
other ="",
});
public class Lotes_Grelha
{
public string article_reference{ get; set; }
public string article_name{ get; set; }
public string other { get; set; }
}