Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 201
  • Last Modified:

Encodings, etc

I'm searching for the method used to write and read cyrillic characters from a standard text file using BufferedReader/BufferedWriter.  I've been unable to find any useful information so far and my attempts at writing and saving in different encodings has failed so far.  

Any ideas?
0
lomidien
Asked:
lomidien
  • 4
  • 2
1 Solution
 
CEHJCommented:
If you're reading, you'll need to know what encoding has been used
0
 
lomidienAuthor Commented:
All the files I'll be reading will be created by myself....all in Unicode format.  Man alive CEHJ, you're always fast to respond!!
0
 
CEHJCommented:
String encoding = "x;
BufferedReader in = new BufferedReader(new InputStreamReader(new FileInputStream("x.txt"), encoding)); //
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
CEHJCommented:
OK - so you know what 'x' is ! ;-)

String encdoing = "UTF8";
BufferedWriter out = new BufferedWriter(new OutputStreamWriter(new FileOutputStream("x.txt"), encoding));
0
 
lomidienAuthor Commented:
Perfect,

Thanks a bunch!  Right on the money!
0
 
CEHJCommented:
8-)
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 4
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now