DevExpress GridControl + EntityFramework-Linq-主详细信息

时间:2020-04-28 13:27:36

标签: c# entity-framework linq

我已编码

gridControl1.DataSource = (from c in dbContext.OPCabs select c).ToList();

可以很好地将“主详细信息”放入网格,但是当我这样做

gridControl1.DataSource = (from c in dbContext.OPCabs select new { c.ID_OP, c.CLI_NOME, c.VAL_TOTAL, c.DAT_ENTREGA }).ToList(); 

不起作用,我在做什么错?

enter image description here

enter image description here

enter image description here

enter image description here

0 个答案:

没有答案
相关问题