hi, I'm new with freepascal-lazarus and have this problem. I have a byte array which contain the bytes from a UTF8 string (these bytes were generated by a .NET app). I'm trying to convert such bytes to a UTF8 string in a lazarus console-app doing the following:
var
myutf8string : UTF8String;
begin
myutf8string := UTF8String(arrUtf8);
writeln(myutf8string);
end;
NOTE: arrUtf8 is a dynamic byte array which in some part of the code has these bytes (dec notation): 65, 66, 67, 68, 69 i.e. ABCDE
However, myutf8string var is being created with just ABCD i.e. it is missing the last char (always as I tested it with other strings/bytes samples. What am I doing wrong? thanks in advance