////////////////////////////////////////////////
with tvOrders.DataController.Summary do
begin
BeginUpdate;
try
with FooterSummaryItems.Add as TcxGridDBTableSummaryItem do
begin
Column := tvOrdersPaymentAmount;
Kind := skSum;
Format := 'SUM = $,0.00;-$,0.00';
end;
finally
EndUpdate;
end;
//Update all open details of the master view (tvCars)
tvCars.DataController.ClearDetails;
end;
//////////////////////////////
以上是TcxGridDBTableSummaryItem
但是我在tcxgriddbbandedtableview 中没有反应不显示??
、、、、、、、、、、、、、、、、、、
with tvOrders.DataController.Summary do
begin
BeginUpdate;
try
SummaryGroups.Clear;
//The first summary group
with SummaryGroups.Add do
begin
//Add proposed grouping column(s)
TcxGridTableSummaryGroupItemLink(Links.Add).Column := tvOrdersCustomerID;
//Add summary items
with SummaryItems.Add as TcxGridDBTableSummaryItem do
begin
Column := tvOrdersPaymentAmount;
Kind := skSum;
Format := 'Amount Paid: $,0';
end;
with SummaryItems.Add as TcxGridDBTableSummaryItem do
begin
Column := tvOrdersPaymentAmount;
Kind := skCount;
Format := 'Records: 0';
end;
end;
//The second summary group
with SummaryGroups.Add do
begin
//Add proposed grouping column(s)
TcxGridTableSummaryGroupItemLink(Links.Add).Column := tvOrdersProductID;
//Add summary items
with SummaryItems.Add as TcxGridDBTableSummaryItem do
begin
Column := tvOrdersQuantity;
Kind := skSum;
Position := spFooter;
Format := 'TOTAL = 0';
end;
with SummaryItems.Add as TcxGridDBTableSummaryItem do
begin
Column := tvOrdersPurchaseDate;
Kind := skMin;
Position := spFooter;
end;
end;
finally
EndUpdate;
end;
end;
、、、、、、、、、、、、、、、、、、、、、、、、、
group的也一样!
根据如下创建的字段 没有名字
With cxgrid1dbbandedtableview1.CreateColumn do
begin
Caption :='月%';
DataBinding.FieldName:='zpmp' ;
Position.BandIndex := 4;
Position.RowIndex := 0;
//Position.LineCount:=1;
Visible := True;
showmessage(cxgrid1dbbandedtableview1.CreateColumn.Name);、、、
end;
从而引起了以上的错误,我想,不知道有没有高手帮忙