How can I fill a Gridview with the result of a Linq query of an EF model.
var vQueryTom = (from tom in cargaDocEntities.REPRESENTATIVE TOMOR select tom);
How can I fill a Gridview with the result of a Linq query of an EF model.
var vQueryTom = (from tom in cargaDocEntities.REPRESENTATIVE TOMOR select tom);
If you put it in your DataSource
it should work.
var vQueryTom = (from tom in cargaDocEntities.TOMADOR_REPRESENTANTE select tom);
myGv.DataSource = vQueryTom.ToList();
o
myGv.DataSource = vQueryTom;
myGv.DataBind();