flash读取外部中文时显示乱码的问题

1 比较老的解决方案:

加一句: System.useCodepage = true;

此法已经不推荐使用, 这是让flash player使用操作系统的编码。如果系统本身就不支持外部文本的编码格式,则可能仍然是乱码。以下节选自《flash cs3 help 》:“Only use this process when you are loading non-Unicode encoded text from an external location and when this text is encoded with the same code page as the user’s computer.”

2 将外部文本用unicode进行编码:

这种做法应该更通用 。同样摘自《flash cs3 help》:“ To ensure that users on all platforms can view external text files used in your Flash applications, encode all external text files as Unicode and leave the system.useCodepageproperty set to false by default.”