You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
14 lines
352 B
Java
14 lines
352 B
Java
5 years ago
|
Writing UTF-8 Encoded Data
|
||
|
|
||
|
public static void main(String args[]){
|
||
|
try{
|
||
|
Writer out = new BufferedWriter(new OutputStreamWriter(
|
||
|
new FileOutputStream("outfilename"), "UTF8"));
|
||
|
out.write(aString);
|
||
|
out.close();
|
||
|
}
|
||
|
catch (Exception ioe){
|
||
|
ioe.printStackTrace();
|
||
|
}
|
||
|
}
|