Apr 9, 2008 2:50 PM
Java Issues... (Java Guru Needed)
Okay, so I'm using Jbuilder and would like to display Japanese Characters in the console The following is the only way I could manage to get it to display albeit it only displays in a popup:
-----------------
--------------------------------------
import java.util.*;
import java.io.*;
import javax.swing.*;
public class japanese_test_class {
public static void main(String[] args)
throws IOException, FileNotFoundException {
PrintWriter output = new PrintWriter("temp.txt", "Cp933");
System.out.println("ひらがな の けんさ です。\u3041");
String test = "ひらがな の けんさ \u3041";
System.out.println(test);
output.println( "\u3041 おい! レイ です。 よろしく おねがいします。Hey There! Rey Here. Pleasure to make your acquaintance." );
output.println( "Hey There! Rey Here. Pleasure to make your acquaintance." );
output.close();
Scanner input = new Scanner(new File("temp.txt"), "Cp933");
JOptionPane.showMessageDialog(null, input.nextLine());
}
}
-----------------------------------
----------------
I would like to have the Japanese display using system.out.println("xxxx") and not have it as a pop up.
(This is my first Java Class but I'm hoping to have my final project be a program that aids students in learning Japanese Characters. I'm using OS X 10.5.2)