Unicode with Fastreport 4.14 and Firebird
Hello,
I'm using Firebird 2.5, accessing data in Delphi 2010 with ZEOS-lib. Database charset is UTF-8 for all textual fields and in Delphi and my application all works fine.
Now I try to generate a report with Fastreport 4.14. I use the IBXDatabase-Component and IBXQuery in Fastreport.
The problem is, that german "umlauts" ar not displayed correct. The text looks like this:
should be:
In this forum I found the response to set RTLeading = true, but it doesn't change anything.
How can I get the correct unicode-Strings displayed in my report?
[edit]
I can set a frxDBDatabase on my form linked to frxReport, add a Zeos-Query and give these data to the report - that works fine.
But I like to define the data-access in my report, not in the Delphi-Sources. Is this possible too?
Thanks,
Siegbert
I'm using Firebird 2.5, accessing data in Delphi 2010 with ZEOS-lib. Database charset is UTF-8 for all textual fields and in Delphi and my application all works fine.
Now I try to generate a report with Fastreport 4.14. I use the IBXDatabase-Component and IBXQuery in Fastreport.
The problem is, that german "umlauts" ar not displayed correct. The text looks like this:
should be:
in Fastreport:Der Apfel und andere Fr??chte.
Der Apfel und andere Fr????chte.
In this forum I found the response to set RTLeading = true, but it doesn't change anything.
How can I get the correct unicode-Strings displayed in my report?
[edit]
I can set a frxDBDatabase on my form linked to frxReport, add a Zeos-Query and give these data to the report - that works fine.
But I like to define the data-access in my report, not in the Delphi-Sources. Is this possible too?
Thanks,
Siegbert
Comments
searching google shows me this way to get a workaround:
- on the form add the event "OnUserFucntion" to the frxReport1-component
- insert code (see below) in the generated function in Delphi
- add the function to frxReport in the form-create-event
- use the new function in report to convert UTF-8 to WideString
Code for the frxReportUserFunction: Code for adding function in form.create:
So code in Delphi looks like this:
Converting UTF-8-Text in the report:
Thanks to Bj?¶rn for this post: http://www.entwickler-ecke.de/topic_Unicod...rt_65744,0.html