Locale currentLocale = java.util.Locale.getDefault();
if (bundle == null) {
try{
bundle = ResourceBundle.getBundle(propertyName, currentLocale);
} catch(java.util.MissingResourceException e){
System.out.println("Could not load Resources");
System.exit(0);
}
}
String value = new String("");
try{
value = bundle.getString(key);
} catch (java.util.MissingResourceException e){
System.out.println("Could not find " + key);}
return value;