utf 8 - How to use Hungarian characters as a key in properties file with ResourceBundle in JAVA? -


I have the attribute file where I get the letters as characters and some integer values. Something like this:

  a = 1b = 2c = 5 ...  

Everything works, but when I use the key Use Hungarian letters (for example: "Ő" or "ű") I found the following exception: "Can not find resource for bundle java.util.PropertyResourceBundle, key." I want something like this:

  ó = 7  

I think my property file does not have UTF-8 encoding, but how can I change it Am I

Did you use instead of \ u0151 = 7 Please try the .properties file in ő = 7 (please see other characters or some other encoding tables).

And to answer your encoding question - Please try using Notepad ++ You can save / convert different four encodings with it.


Comments