Renaming data fields in a Crosstab
I am translating an application into another language (Spanish). The
application was developed using Delphi 5 & ReportBuilder 5.55, in which I
make generous use of crosstab reports.
I have the following problem:
- The crosstabs use the standard table field names as column headers. Of
course, these field names have been designed in the Data Module using
English (for example, "Transaction_Amount").
- When translating these crosstab reports into Spanish, I would like to
change the field name to "Monto_de_la_Transaccion" (so that the field shows
up properly into the crosstab reports).
How can I do this?
THANKS.
Best regards,
Ray
application was developed using Delphi 5 & ReportBuilder 5.55, in which I
make generous use of crosstab reports.
I have the following problem:
- The crosstabs use the standard table field names as column headers. Of
course, these field names have been designed in the Data Module using
English (for example, "Transaction_Amount").
- When translating these crosstab reports into Spanish, I would like to
change the field name to "Monto_de_la_Transaccion" (so that the field shows
up properly into the crosstab reports).
How can I do this?
THANKS.
Best regards,
Ray
This discussion has been closed.
Comments
OnGetCaptionText event of the crosstab to read the caption text and change
it before it is rendered.
Cheers,
Jim Bennett
Digital Metaphors
http://www.digital-metaphors.com
info@digital-metaphors.com
OnGetCaptionText event, I am not able to descipher how to change the
variable's caption. Could you please give me an example (in code)? For
example, how would you make the crosstab's caption "State" read "Estado" (in
your own demo #127)?
THANKS!
Best regards,
Ray
{---------------------------------------------------------------------------
---}
{ TfrmCT127.CrossTabGetCaptionTextEvent }
procedure TfrmCT127.CrossTabGetCaptionTextEvent(Sender: TObject; aElement:
TppElement; aColumn, aRow: Integer; const aDisplayFormat: String; aValue:
Variant; var aText: String);
begin
if (aText = 'State') and (aColumn = 1) and (aRow = 0) then
begin
aText := 'Estado';
end
else
aText := aText + ' (C)';
end; {procedure, CrossTabGetCaptionTextEvent}
Cheers,
Jim Bennett
Digital Metaphors
http://www.digital-metaphors.com
info@digital-metaphors.com
When you pair up a top-notch software product with consistently excellent
developer support, you can only win and win big: congratulations!
Best regards,
Ray