can writeln output null terminated wide character arrays ? lazarus / 61-Beginners ---------------------------------------------------------------------- 440bx · 2018-07-09 02:45 Hello, The following works fine Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i var   anarrowstring : pchar = 'this is a "narrow" string';...begin   writeln(anarrowstring);end. The compiler is, as expected, perfectly happy with that.  On the other hand, if pchar is changed to pwidechar, the compiler emits an error stating that variables of that type can neither be read nor written.  e,g.  the following does not work : Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i var   awidestring : pwidechar = 'this is a "wide" string';...begin   writeln(awidestring);end.  Did I miss something or is it really the case that writeln cannot write wide characters to the console ?   I can always import wprintf from user32.dll but, I'd rather keep things "pascal" if possible. Thank you for your help. ---------------------------------------------------------------------- Thaddy · 2018-07-09 05:05 Cast to unicodestring? Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i program untitled;var   awidestring : pwidechar = 'this is a "wide" string'; begin   writeln(unicodestring(awidestring));end. ---------------------------------------------------------------------- 440bx · 2018-07-09 16:19 That works .  Thank you Thaddy.