perltk wrote:UTF-

  Hi,

Then I read the file and put in textctrl&  listbox and it looked good.
Also print to STDOUT correctly - AND I did NOT have to use
the 'perl -C' or :utf8 encoding for things to work.

So I guess it is the strings that are being bad.

BUT how come the bad data show correctly on the command line if I use 'perl -C'?
And show correctly in Tk ?

Different defaults? It all depends on the charset/encoding of the data (ISO-8859-1, UTF-8, EUC-JP, ...), how Tk handles strings, possibly the locale.

I cannot modify the data - not my data.  What can I do to correct
or atleast get something other than a blank string ?

  Maybe you just need a call to Encode::decode($db_encoding, $db_data)?
Even easier, follow Johan Vromans' advice of having the database return the data in the correct encoding?

HTH,
Mattia

Reply via email to