• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Accented characters in XLS with Apache POI HSSF

 
Ranch Hand
Posts: 70
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ok, got a problem that I can't seem to find any useful, relevant information on so I really need some help! I am creating Excel files with Apache POI in my application. Everything is working great except accented characters are showing up wrongly like Guant,namo/Guantn�namo, C,te D'Ivoire/C�te D'Ivoire etc.

Just replacing the accented characters with their closest equivalent like '�' to 'o' is no good, my boss does *not* compromise I can create a simple CSV easily and it all works fine with that, and it can be loaded into Excel and works there too (but that's not good enough either).

Thanks in advance!
 
Ranch Hand
Posts: 456
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
i used apache poi as well and was unable to figure out how to print a euro-symbol. :-(

in some points poi does not seem to be very mature.

the world's most stupid work-around, but maybe worth giving it a try if you are really desperate: don't create a new document, use a existing one and see if utf8 still gets lost. if not, you can fake to create a new document, but transparently modify an existing one.

btw: i think google will show much better forums for this type of questions. did you check if apache has one for poi?

regards,
jan
 
Bartender
Posts: 10336
Hibernate Eclipse IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Did you set the encoding before setting the cell value?
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic