El 29/04/2020 a las 04:44, Zamrony P. Juhara via fpc-pascal escribió:
No it does not work. Docs says literal string needs to be quoted with "Zamrony P. Juhara On Wed, Apr 29, 2020 at 9:37, Alexander Grotewohl <[email protected]> wrote: _______________________________________________ fpc-pascal maillist - [email protected] <mailto:[email protected]> https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal _______________________________________________ fpc-pascal maillist - [email protected] https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
This format works for me: 'ddd, dd mmm yyyy hh:nn:ss' Fpc 3.04, windows 7, 32bits, and fpc 3.04, Linux, 64bits. Some points: * "m" is allowed for minutes , nevertheless, I use for minutes "n", not "m". * I have suppressed the time zone information, I couldn't see how to set it in formatStrings, nevertheless, it ignores the GMT, or anything after time in input string with no error. * I think that the scanner ignores the character after weekday, it expects a separator, as long as it is not a "d" if will accept and skip anything. So the double quote after the three "d" of 'ddd", "dd is ignored and everything breaks. It's a little confusing. * The weekday and month depend on you local. * using non-ascii characters breaks things. In Spanish Wednesday is "Miércoles" (e with acute accent) and Tuesday is "Martes": "mar, 28 abr 2020" works, but "Mié, 29 Abr 2020" fails. I think that the problem is that é uses two bytes in UTF-8, but scan only deals properly with single byte characters -- Saludos Santiago A.
_______________________________________________ fpc-pascal maillist - [email protected] https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
