To write a BOM in UTF-8 you need PrintStream.print(), not PrintStream.write().
Also if you want to have BOM in your csv file, I guess you need to print a BOM after putNextEntry().
Read full article from character encoding - How to add a UTF-8 BOM in java - Stack Overflow
No comments:
Post a Comment