DBGridEh1.FooterRowCount:=1;
DBGridEh1.SumList.Active:=True;
DBGridEh1.FootColor:=clInfoBk;
DBGridEh1.Columns[0].Footer.ValueType := fvtStaticText;
DBGridEh1.Columns[0].Footer.Value := '总计:';
DBGridEh1.Columns[1].Footer.ValueType := fvtCount; //fvtSum
另:在DataSource的OnDataChange中,DBGridEh1.SumList.RecalcAll;
DBGridEh1.SumList.Active:=True;
DBGridEh1.FootColor:=clInfoBk;
DBGridEh1.Columns[0].Footer.ValueType := fvtStaticText;
DBGridEh1.Columns[0].Footer.Value := '总计:';
DBGridEh1.Columns[1].Footer.ValueType := fvtCount; //fvtSum
另:在DataSource的OnDataChange中,DBGridEh1.SumList.RecalcAll;
博客主要介绍了DBGridEh1控件的相关设置,包括设置页脚行数、激活求和列表、设置页脚颜色等,还对列的页脚值类型和值进行了设置。另外,提到在DataSource的OnDataChange事件中使用DBGridEh1.SumList.RecalcAll进行数据重算。


被折叠的 条评论
为什么被折叠?



