Hello,
Thank you very much for your help. It worked for me:
Try
AssignFile(fp, UTF8ToSys(filepath));
Reset(fp);
while not eof(fp) do begin
ReadLn(fp,auxstr);
fEditor.SynEdit1.Lines.Add(ConvertEncoding(auxstr, 'ISO-8859-1', 'UTF8'));
end;
CloseFile(fp);
except
MessageDlg('Unable to read the file!', mtWarning, [mbYes], 0);
exit;
end;
I really appreciate all the contributions on this forum.
Carles