Monday, 23 June 2008

Eclipse - Save UTF-8 character

Error message from Eclipse when you try to save the file
========================================================================
save could not be completed.
Reason:
some characters cannot be mapped using "ISO-8859-1" character encoding.
Either change the encoding or remove the characters which are not supported
by the "ISO-8859-1" character encoding.
==========================================================================

Please go to "Windows > Preferences > General > Content Types > Text > JSP or ...

JSP > Default encoding > UTF-8 and click update button

45 comments:

Vo Ngoc said...

Thanks!

lewo said...

thanks.

srinivasan said...

Thank You :)

Joe said...

Thank you, this was frustrating the heck out of me.

на изток от рая said...

thanks a lot!
Greets
ng_agi

Anonymous said...

Thanks :)

Anonymous said...

Thanks alot! it was really helpfull!

Jeevan said...

Thanks,Really helpful.

Frank said...

I find it rare that the first result on Google solves an Eclipse problem, but you nailed it for me- Thanks!

Jay said...

Thanks! it works.

Anonymous said...

Really thanks.

n0n3 said...

thx a lot!

Anonymous said...

Thanks you very much

Yusuke said...

great! thanks!

Anonymous said...

Many thanks.

Anonymous said...

Nice :)

Anonymous said...

Thanks man, obviously, quite some people need it.
Reagrds,

romunov said...

Life saver!

Anonymous said...

Thanks!!

swathi said...

thanks

bitkidoku said...

This was the only useful post I have seen on this error. Thank you very much!

Laura said...

It's great when you find the answer to a question on the first google search result. Thanks!

Anonymous said...

Thanks for the tip!!!

RATS said...

Thanks ! That was useful :)

Hemachandra said...

Thank you so much.
It helped me.

Anonymous said...

thank u

ChesserCat said...

Alternately, if you have a reason for not using UTF-8:

* pull the text into Vim
* convert to Hex
* use regex searches to find a code which is greater than 7F
* fix the offending character(s)
* convert back
* copy and paste fixed code back to Eclipse

In my case, I had some text in a web page which I had copied and pasted from an e-mail. The text had a Windows-specific single-quote, instead of a regular, ASCII single quote.

Clearly, anything which will show you hex values for your text and allow you to spot a value greater than 7F will accomplish the same thing. Is there a way to do this in Eclipse? I ask because I don't know of one.

Adam said...

Thanks!!!

Anonymous said...

Thanks you, it's helped me a lot!

Anonymous said...

Vielen Dank

Anonymous said...

Vielen Dank

Anonymous said...

Thank you. This was very helpful.

Reda said...

Thanks a lot, it work

Oleg said...

thank you very much

Anonymous said...

thanks a lot!

vikrantmanne said...

Thanks you so much. It helped !

Anonymous said...

Thanks!

a member of the LLJ Property team said...

Thanks

Anonymous said...

Thank you so much mate.

Anonymous said...

Another thanks!

JrQA said...

It is not working for me :( I have to select a number like ≤ -150. but Eclipse gives me the same error again and again.

JrQA said...

It is not working for me :( I have to select a number like ≤ -150. but Eclipse gives me the same error again and again.

Danil Ozherelyev said...

Thanks! It works!!

Danil Ozherelyev said...

You're great! Thanks a ton!

Pride said...

Thank you. This worked nicely for me.