rb doesn't know the encoding when you read from the database.
when you read a database cursor, define its encoding as UTF8 before you
hand it to the editfield.
matthias
On Sunday, Mar 30, 2003, at 15:15 Europe/Zurich, Olivier Scherler wrote:
I'm testing the database features of RB. I have a REALDatabase with a
simple
table with ID, Name and FirstName and I use a DataControl to browse
and edit it,
the standard tutorial way. However, when I create a new record with
8-bit
characters in a field, I get terrible results. Example:
- I enter "Gérard Lambert", click Insert (Object bound to Insert in the
DataControl)
- I get "Gérard Lambert", typical MacRoman misrepresentation of UTF-8
data.
- If I browse the records, the next time I get "Gérard Lambert",
less
typical MacRoman misrepresentation of the MacRoman misrepresentation
of UTF-8
data.
- And so on:
"G‚Äö√Ñ√∂‚àö√ë‚àö‚àÇ‚Äö√†√∂‚àö√´‚Äö√†√∂‚Äö√†√á‚Äö√Ñ√∂‚àö‚Ć‚àö‚àÇ‚Äö√Ñ√
∂‚àö√ë‚Äö
√тĆ‚Äö√Ñ√∂‚àö‚Ć‚àö‚àÇ‚Äö√Ñ√∂‚àö‚Ć‚àö√°¬¨¬®¬¨¬Æ¬¨¬®¬¨√ܬ¨¬®¬¨¬Æ¬¨¬®¬
¨¬©rard
Lambert" after a while.
What should I do? I tried using a TextConverter in the Validate event
of the
DataControl when inserting records, but I get worst results. And it
seems the
problem is not at the insertion (RB converts MacRoman to UTF-8) but at
the
retrieval.
---------------------------------------------------------
Matthias Buercher matti at belle-nuit dot com www.belle-nuit.com
---------------------------------------------------------
war in iraq - not in my name
http://www.gssa.ch/antiguerre/
http://www.unitedforpeace.org
---
A searchable archive of this list is available at:
<http://support.realsoftware.com/listarchives/search.php>
Unsubscribe:
<mailto:realbasic-nug-off at lists dot realsoftware dot com>
Subscribe to the digest:
<mailto:realbasic-nug-digest at lists dot realsoftware dot com>
.
|