Problem with greek characters using java
- by Subhendu Mahanta
I am trying to write greek characters to a file using java like this:
String greek = "\u03c1\u03ae\u03bc. \u03c7\u03b1\u03b9\u03c1\u03b5\u03c4\u03ce";
try {
BufferedWriter out = new BufferedWriter(new FileWriter("E:\\properties\\outfilename.txt"));
out.write(greek);
out.close();
} catch (IOException e) {
}
Not working. Tried to use javac -encoding ISO-8859-7. Also tried java -Dfile.encoding=ISO-8859-7.
Assuming that as I do not have greek font in my pc, I downloaded achillies (greek font - Ach4.ttf).Installed it by going to control panel fonts.
Any ideas?