On Fri, 2006-12-22 at 00:23 +0000, Exile In Paradise wrote:
> import java.util.ResourceBundle;
> import java.util.Locale;
>
> public class TranslatedPrompts {
> public static void main(String[] args) {
> // show en_US versions
> ResourceBundle rb =
> ResourceBundle.getBundle("Test",new Locale("en","US"));
> System.out.println(rb.getString("myapp.Prompt1"));
> System.out.println(rb.getString("myapp.Prompt2"));
> // switch to es_SP versions
> rb = ResourceBundle.getBundle("Test",new Locale("en","US"));
This line should be changed to:
rb = ResourceBundle.getBundle("Test",new Locale("es","SP"));
> System.out.println(rb.getString("myapp.Prompt1"));
> System.out.println(rb.getString("myapp.Prompt2"));
> }
> }
>
Darnit, I hate code typos.
Drat me for being in a rush.
Enjoy... and happy holidays!
--
Exile In Paradise
One can't proceed from the informal to the formal by formal means.