View Single Post
  #2 (permalink)  
Old 08-06-2007, 05:48 AM
katie katie is offline
Member
 
Join Date: Jul 2007
Posts: 41
katie is on a distinguished road
if the content of the foo.txt file is a collection of ISO8859-1 characters:
Code:
BufferedReader br = new BufferedReader (new InputStreamReader(new FileInputStream("foo.txt"), "ISO8859_1"));
Read them lines into an ArrayList. Then,

Code:
PrintWriter pw = new PrintWriter("foo.txt", "UTF8");
would overwrite the foo.txt with UTF-8 characters.
Reply With Quote