[Lazarus] Have cp1251 displaying problem from MySQL database.
webpirat at mail.ru
Fri Jul 24 16:27:08 CEST 2009
Андрей Гусев (Andrey Gusev) wrote:
> Hello all.
> I have with cp1251 displaying problem from MySQL database.
> It seems, 1.5 years ago don't has problems.
> MySQL is 5.0.45-community-nt
> OS is WinXP
> Lazarus 0.9.26.2 + fpc 2.2.2 installed from distributive
> Charset in MySQL50Connection has 'cp1251' value,
> also 'set character set cp1251' was tried.
> In what there can be a problem ?
> DBGrid runtime snap is attached.
> Test Project also attached.
If you are working with Lazarus then all strings you pass to LCL must be
utf8 encoded. I suspect you are passing cp1251 encoded strings and
that's why you see '?' characters in your dbgrid.
More information about the Lazarus