[Gambas-user] different UTF-8

Gianluigi bagonergi at ...626...
Mon Oct 10 19:51:39 CEST 2016


You can see here: http://gambaswiki.org/wiki/lang/conv

(Look that your mail is read as spam)

Regards
Gianluigi

2016-10-10 15:43 GMT+02:00 Busturia Xx <casa.busturia at ...397...>:

> Hi
>
> When I paint a text in my drawing area I get bad characters. I think that
> it is because I red that text from mysql.
>
> Mysql use collation UTF8_mb4_unicode_ci and gambas use utf8 general.
>
> I have this code
>
> Dim Rs as result, MyField as string
>
> ...
> ...
> MyField=Rs!field_name
>
> Paint.begin(MyDrawingArea)
> ...
> ...
> Paint.text(MyField)
> Paint.end
>
> I could see that MyField value is 'abc 1" but I get "abc " and two bad
> characters.
>
> I tried without database field
>
> MyField="abc 1"
>
> Paint.begin(MyDrawingArea)
> ...
> ...
> Paint.text(MyField)
> Paint.end
>
> And it works fine, so I think that all the encoding problems above are
> caused by text being submitted in one character set and viewed in another.
>
> What can I do?
>
> ------------------------------------------------------------
> ------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, SlashDot.org! http://sdm.link/slashdot
> _______________________________________________
> Gambas-user mailing list
> Gambas-user at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gambas-user
>



More information about the User mailing list