TCRDBGrid and SummaryMode

Discussion of open issues, suggestions and bugs regarding MyDAC (Data Access Components for MySQL) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
GuzunNicolae
Posts: 78
Joined: Wed 17 Jan 2007 14:16

TCRDBGrid and SummaryMode

Post by GuzunNicolae » Thu 24 May 2007 11:11

I have a question on TCRDBGrid.
TCRColumn has has a property SummaryMode.
There I can choose to show either average, sum etc of the column. But what if I want to make my custom detail?

I assume that setting SummaryMode to smLabel will help me. But I do not know how to use it. And in MyDAC Help I do not have anything about this.

Can you please tell me how can I make a custom detail on a column?

Thanks

Antaeus
Posts: 2098
Joined: Tue 14 Feb 2006 10:14

Post by Antaeus » Fri 25 May 2007 09:27

You can assign a custom summary value for a column in this way:

Code: Select all

 CRDBGrid1.Columns[2].SummaryMode := smLabel;
 CRDBGrid1.Columns[2].TotalString := 'some_custom_value';
We will add the description of the smLabel summary mode in the CRControls help in the next MyDAC build.

eduardosic
Posts: 387
Joined: Fri 18 Nov 2005 00:26
Location: Brazil

CRDBGrid..

Post by eduardosic » Fri 25 May 2007 22:25

Antaeus wrote:You can assign a custom summary value for a column in this way:

Code: Select all

 CRDBGrid1.Columns[2].SummaryMode := smLabel;
 CRDBGrid1.Columns[2].TotalString := 'some_custom_value';
We will add the description of the smLabel summary mode in the CRControls help in the next MyDAC build.
TCRDBGrid it is an excellent component, one more time corelab presents an excellent solution.

Without saying in Mydac 5 and the DisconnectModel technology that is the best thing of the world.

Post Reply