解決FastReport 4.7X中文亂碼問題
FastReport 4.7x雖然已支援unicode,也附有Taiwan(繁中)的介面,但轉換後仍是一大堆?號。 其中問題出在Res\frcc.exe,frcc轉檔後的儲存格式為Ansi並非UTF-8,經手動轉換並更改中文字被截斷的部份。 此部份可下載frcc.rar,解壓後取代FastReport 4\Res\frcc.exe 另一部份為frxRes.pas,字碼轉換的問題,應修改: procedure TfrxResources.AddXML(const Str: AnsiString); var Stream: TStringStream; begin Stream := TStringStream.Create(Str); LoadFromStream(Stream); Stream.Free; end; 修改為 procedure TfrxResources.AddXML(const Str: AnsiString); var Stream: TStringStream; begin {$IFDEF Delphi12} Stream := TStr ingStream.Create(UTF8Encode(String(str))); {$ELSE} Stream := TStringStream.Create(Str); {$ENDIF} LoadFromStream(Stream); Stream.Free; end; 完成後執行:FastReport 4 recompile wizard 1. Change language to: "Taiwan" 2. Compile 3. Recompile all package 4. Compile ingStream.Create(UTF8Encode(String(str))); {$ELSE} Stream := TStringStream.Create(Str); {$ENDIF} LoadFromStream(Stream); Stream.Free; end; 完成後執行:FastReport 4 recompile wizard 1. Change language to: "Taiwan" 2. Compile 3. Recompile all package 4. Compile
下载地址
用户评论
这个没有用太明白,后来自己解决了 谢谢
虽然后来乱码问题解决了,还是得感谢